class QuickEditEntityFieldAccessCheck implements AccessInterface, QuickEditEntityFieldAccessCheckInterface (View source)

Access check for in-place editing entity fields.

Methods

access(EntityInterface $entity, string $field_name, string $langcode, AccountInterface $account)

Checks Quick Edit access to the field.

accessEditEntityField(EntityInterface $entity, string $field_name)

Checks access to edit the requested field of the requested entity.

validateRequestAttributes(EntityInterface $entity, $field_name, $langcode)

Validates request attributes.

Details

AccessResultInterface access(EntityInterface $entity, string $field_name, string $langcode, AccountInterface $account)

Checks Quick Edit access to the field.

Use the $account argument: https://www.drupal.org/node/2266809.

Parameters

EntityInterface $entity

The entity containing the field.

string $field_name

The field name.

string $langcode

The langcode.

AccountInterface $account

The currently logged in account.

Return Value

AccessResultInterface

The access result.

AccessResultInterface accessEditEntityField(EntityInterface $entity, string $field_name)

Checks access to edit the requested field of the requested entity.

Parameters

EntityInterface $entity

The entity.

string $field_name

The field name.

Return Value

AccessResultInterface

The access result.

protected validateRequestAttributes(EntityInterface $entity, $field_name, $langcode)

Validates request attributes.

Parameters

EntityInterface $entity
$field_name
$langcode