You are here

class NumberFormatDefinitionEvent in Price 8

Same name and namespace in other branches
  1. 3.x src/Event/NumberFormatDefinitionEvent.php \Drupal\price\Event\NumberFormatDefinitionEvent
  2. 2.0.x src/Event/NumberFormatDefinitionEvent.php \Drupal\price\Event\NumberFormatDefinitionEvent
  3. 2.x src/Event/NumberFormatDefinitionEvent.php \Drupal\price\Event\NumberFormatDefinitionEvent
  4. 3.0.x src/Event/NumberFormatDefinitionEvent.php \Drupal\price\Event\NumberFormatDefinitionEvent

Defines the number format definition event.

Hierarchy

Expanded class hierarchy of NumberFormatDefinitionEvent

See also

\Drupal\price\Event\PriceEvents

1 file declares its use of NumberFormatDefinitionEvent
NumberFormatRepository.php in src/Repository/NumberFormatRepository.php

File

src/Event/NumberFormatDefinitionEvent.php, line 12

Namespace

Drupal\price\Event
View source
class NumberFormatDefinitionEvent extends Event {

  /**
   * The number format definition.
   *
   * @var array
   */
  protected $definition;

  /**
   * Constructs a new NumberFormatDefinitionEvent.
   *
   * @param array $definition
   *   The number format definition.
   */
  public function __construct(array $definition) {
    $this->definition = $definition;
  }

  /**
   * Gets the number format definition.
   *
   * @return array
   *   The number format definition.
   */
  public function getDefinition() {
    return $this->definition;
  }

  /**
   * Sets the number format definition.
   *
   * @param array $definition
   *   The number format definition.
   *
   * @return $this
   */
  public function setDefinition(array $definition) {
    $this->definition = $definition;
    return $this;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
NumberFormatDefinitionEvent::$definition protected property The number format definition.
NumberFormatDefinitionEvent::getDefinition public function Gets the number format definition.
NumberFormatDefinitionEvent::setDefinition public function Sets the number format definition.
NumberFormatDefinitionEvent::__construct public function Constructs a new NumberFormatDefinitionEvent.