You are here

class PdbDiscoveryEvent in Decoupled Blocks 8

Provides an event to handle user custom search dirs.

Hierarchy

  • class \Drupal\pdb\Event\PdbDiscoveryEvent extends \Symfony\Component\EventDispatcher\Event

Expanded class hierarchy of PdbDiscoveryEvent

1 file declares its use of PdbDiscoveryEvent
ComponentDiscovery.php in src/ComponentDiscovery.php

File

src/Event/PdbDiscoveryEvent.php, line 10

Namespace

Drupal\pdb\Event
View source
class PdbDiscoveryEvent extends Event {

  /**
   * Name of the PDB discovery search dirs event.
   */
  const SEARCH_DIRS = 'pdb.search_dirs';

  /**
   * Component discovery search dirs.
   *
   * @var array
   */
  protected $dirs;

  /**
   * PdbDiscoveryEvent constructor.
   *
   * @param array $dirs
   *   The discovery search dirs.
   */
  public function __construct(array $dirs) {
    $this->dirs = $dirs;
  }

  /**
   * Get the dirs.
   *
   * @return array
   *   The stored discovery search dirs.
   */
  public function getDirs() {
    return $this->dirs;
  }

  /**
   * Set the dirs.
   *
   * @param array $dirs
   *   Discovery search dirs to store.
   */
  public function setDirs(array $dirs) {
    return $this->dirs = $dirs;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
PdbDiscoveryEvent::$dirs protected property Component discovery search dirs.
PdbDiscoveryEvent::getDirs public function Get the dirs.
PdbDiscoveryEvent::SEARCH_DIRS constant Name of the PDB discovery search dirs event.
PdbDiscoveryEvent::setDirs public function Set the dirs.
PdbDiscoveryEvent::__construct public function PdbDiscoveryEvent constructor.