You are here

class EntityFieldValueAccessDeniedEvent in Permissions by Term 8.2

Same name and namespace in other branches
  1. 8 modules/permissions_by_entity/src/Event/EntityFieldValueAccessDeniedEvent.php \Drupal\permissions_by_entity\Event\EntityFieldValueAccessDeniedEvent

Class EntityFieldValueAccessDeniedEvent.

@package Drupal\permissions_by_entity\Event

Hierarchy

Expanded class hierarchy of EntityFieldValueAccessDeniedEvent

2 files declare their use of EntityFieldValueAccessDeniedEvent
AccessChecker.php in modules/permissions_by_entity/src/Service/AccessChecker.php
RemoveEntityFromViewEventSubscriber.php in modules/permissions_by_entity/src/EventSubscriber/RemoveEntityFromViewEventSubscriber.php

File

modules/permissions_by_entity/src/Event/EntityFieldValueAccessDeniedEvent.php, line 14

Namespace

Drupal\permissions_by_entity\Event
View source
class EntityFieldValueAccessDeniedEvent extends Event {

  /**
   * The field that contains the fieldable entity.
   *
   * @var \Drupal\Core\Field\FieldItemListInterface
   */
  private $field;

  /**
   * A fieldable entity.
   *
   * @var \Drupal\Core\Entity\FieldableEntityInterface
   */
  private $entity;

  /**
   * The user id.
   *
   * @var int
   */
  private $uid;

  /**
   * The current index.
   *
   * @var int
   */
  private $index;

  /**
   * Sets the field.
   *
   * @param \Drupal\Core\Field\FieldItemListInterface $field
   *   The field that contains the fieldable entity.
   */
  public function setField(FieldItemListInterface $field) {
    $this->field = $field;
  }

  /**
   * Returns the field.
   *
   * @return \Drupal\Core\Field\FieldItemListInterface
   *   The field that contains the fieldable entity.
   */
  public function getField() {
    return $this->field;
  }

  /**
   * Sets the fieldable entity.
   *
   * @param \Drupal\Core\Entity\FieldableEntityInterface $entity
   *   A fieldable entity.
   */
  public function setEntity(FieldableEntityInterface $entity) {
    $this->entity = $entity;
  }

  /**
   * Returns the entity.
   *
   * @return \Drupal\Core\Entity\FieldableEntityInterface
   *   A fieldable entity.
   */
  public function getEntity() {
    return $this->entity;
  }

  /**
   * Sets the uid.
   *
   * @param int $uid
   *   The user id.
   */
  public function setUid($uid) {
    $this->uid = $uid;
  }

  /**
   * Returns the uid.
   *
   * @return int
   *   The user id.
   */
  public function getUid() {
    return $this->uid;
  }

  /**
   * Sets the index.
   *
   * @param int $index
   *   The current index.
   */
  public function setIndex($index) {
    $this->index = $index;
  }

  /**
   * Returns index.
   *
   * @return int
   *   The current index.
   */
  public function getIndex() {
    return $this->index;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
EntityFieldValueAccessDeniedEvent::$entity private property A fieldable entity.
EntityFieldValueAccessDeniedEvent::$field private property The field that contains the fieldable entity.
EntityFieldValueAccessDeniedEvent::$index private property The current index.
EntityFieldValueAccessDeniedEvent::$uid private property The user id.
EntityFieldValueAccessDeniedEvent::getEntity public function Returns the entity.
EntityFieldValueAccessDeniedEvent::getField public function Returns the field.
EntityFieldValueAccessDeniedEvent::getIndex public function Returns index.
EntityFieldValueAccessDeniedEvent::getUid public function Returns the uid.
EntityFieldValueAccessDeniedEvent::setEntity public function Sets the fieldable entity.
EntityFieldValueAccessDeniedEvent::setField public function Sets the field.
EntityFieldValueAccessDeniedEvent::setIndex public function Sets the index.
EntityFieldValueAccessDeniedEvent::setUid public function Sets the uid.