You are here

class ExtractEvent in Zircon Profile 8

Same name in this branch
  1. 8 vendor/zendframework/zend-hydrator/src/Aggregate/ExtractEvent.php \Zend\Hydrator\Aggregate\ExtractEvent
  2. 8 vendor/zendframework/zend-stdlib/src/Hydrator/Aggregate/ExtractEvent.php \Zend\Stdlib\Hydrator\Aggregate\ExtractEvent
Same name and namespace in other branches
  1. 8.0 vendor/zendframework/zend-hydrator/src/Aggregate/ExtractEvent.php \Zend\Hydrator\Aggregate\ExtractEvent

Event triggered when the {data from an object

Hierarchy

  • class \Zend\Hydrator\Aggregate\ExtractEvent extends \Zend\EventManager\Event

Expanded class hierarchy of ExtractEvent

See also

AggregateHydrator} extracts

1 file declares its use of ExtractEvent
ExtractEvent.php in vendor/zendframework/zend-stdlib/src/Hydrator/Aggregate/ExtractEvent.php

File

vendor/zendframework/zend-hydrator/src/Aggregate/ExtractEvent.php, line 18

Namespace

Zend\Hydrator\Aggregate
View source
class ExtractEvent extends Event {
  const EVENT_EXTRACT = 'extract';

  /**
   * {@inheritDoc}
   */
  protected $name = self::EVENT_EXTRACT;

  /**
   * @var object
   */
  protected $extractionObject;

  /**
   * @var array
   */
  protected $extractedData = [];

  /**
   * @param object $target
   * @param object $extractionObject
   */
  public function __construct($target, $extractionObject) {
    $this->target = $target;
    $this->extractionObject = $extractionObject;
  }

  /**
   * Retrieves the object from which data is extracted
   *
   * @return object
   */
  public function getExtractionObject() {
    return $this->extractionObject;
  }

  /**
   * @param object $extractionObject
   *
   * @return void
   */
  public function setExtractionObject($extractionObject) {
    $this->extractionObject = $extractionObject;
  }

  /**
   * Retrieves the data that has been extracted
   *
   * @return array
   */
  public function getExtractedData() {
    return $this->extractedData;
  }

  /**
   * @param array $extractedData
   *
   * @return void
   */
  public function setExtractedData(array $extractedData) {
    $this->extractedData = $extractedData;
  }

  /**
   * Merge provided data with the extracted data
   *
   * @param array $additionalData
   *
   * @return void
   */
  public function mergeExtractedData(array $additionalData) {
    $this->extractedData = array_merge($this->extractedData, $additionalData);
  }

}

Members

Namesort descending Modifiers Type Description Overrides
ExtractEvent::$extractedData protected property
ExtractEvent::$extractionObject protected property
ExtractEvent::$name protected property
ExtractEvent::EVENT_EXTRACT constant
ExtractEvent::getExtractedData public function Retrieves the data that has been extracted
ExtractEvent::getExtractionObject public function Retrieves the object from which data is extracted
ExtractEvent::mergeExtractedData public function Merge provided data with the extracted data
ExtractEvent::setExtractedData public function
ExtractEvent::setExtractionObject public function
ExtractEvent::__construct public function