You are here

class FieldStorageDefinitionEvent in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/lib/Drupal/Core/Field/FieldStorageDefinitionEvent.php \Drupal\Core\Field\FieldStorageDefinitionEvent

Defines a base class for all field storage definition events.

Hierarchy

  • class \Symfony\Component\EventDispatcher\Event
    • class \Symfony\Component\EventDispatcher\GenericEvent implements \Symfony\Component\EventDispatcher\ArrayAccess, \Symfony\Component\EventDispatcher\IteratorAggregate

Expanded class hierarchy of FieldStorageDefinitionEvent

File

core/lib/Drupal/Core/Field/FieldStorageDefinitionEvent.php, line 15
Contains \Drupal\Core\Field\FieldStorageDefinitionEvent.

Namespace

Drupal\Core\Field
View source
class FieldStorageDefinitionEvent extends GenericEvent {

  /**
   * The field storage definition.
   *
   * @var \Drupal\Core\Field\FieldStorageDefinitionInterface
   */
  protected $fieldStorageDefinition;

  /**
   * The original field storage definition.
   *
   * @var \Drupal\Core\Field\FieldStorageDefinitionInterface
   */
  protected $original;

  /**
   * Constructs a new FieldStorageDefinitionEvent.
   *
   * @param \Drupal\Core\Field\FieldStorageDefinitionInterface $field_storage_definition
   *   The field storage definition.
   * @param \Drupal\Core\Field\FieldStorageDefinitionInterface $original
   *   (optional) The original field storage definition. This should be passed
   *   only when updating the storage definition.
   */
  public function __construct(FieldStorageDefinitionInterface $field_storage_definition, FieldStorageDefinitionInterface $original = NULL) {
    $this->fieldStorageDefinition = $field_storage_definition;
    $this->original = $original;
  }

  /**
   * The field storage definition.
   *
   * @return \Drupal\Core\Field\FieldStorageDefinitionInterface
   */
  public function getFieldStorageDefinition() {
    return $this->fieldStorageDefinition;
  }

  /**
   * The original field storage definition.
   *
   * @return \Drupal\Core\Field\FieldStorageDefinitionInterface
   */
  public function getOriginal() {
    return $this->original;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
Event::$dispatcher private property
Event::$name private property
Event::$propagationStopped private property
Event::getDispatcher Deprecated public function Returns the EventDispatcher that dispatches this Event.
Event::getName Deprecated public function Gets the event's name.
Event::isPropagationStopped public function Returns whether further event listeners should be triggered.
Event::setDispatcher Deprecated public function Stores the EventDispatcher that dispatches this Event.
Event::setName Deprecated public function Sets the event's name property.
Event::stopPropagation public function Stops the propagation of the event to further event listeners.
FieldStorageDefinitionEvent::$fieldStorageDefinition protected property The field storage definition.
FieldStorageDefinitionEvent::$original protected property The original field storage definition.
FieldStorageDefinitionEvent::getFieldStorageDefinition public function The field storage definition.
FieldStorageDefinitionEvent::getOriginal public function The original field storage definition.
FieldStorageDefinitionEvent::__construct public function Constructs a new FieldStorageDefinitionEvent. Overrides GenericEvent::__construct
GenericEvent::$arguments protected property Array of arguments.
GenericEvent::$subject protected property Event subject.
GenericEvent::getArgument public function Get argument by key.
GenericEvent::getArguments public function Getter for all arguments.
GenericEvent::getIterator public function IteratorAggregate for iterating over the object like an array.
GenericEvent::getSubject public function Getter for subject property.
GenericEvent::hasArgument public function Has argument.
GenericEvent::offsetExists public function ArrayAccess has argument.
GenericEvent::offsetGet public function ArrayAccess for argument getter.
GenericEvent::offsetSet public function ArrayAccess for argument setter.
GenericEvent::offsetUnset public function ArrayAccess for unset argument.
GenericEvent::setArgument public function Add argument to event.
GenericEvent::setArguments public function Set args property.