class PreCreateEvent
Event fired before a stage directory is created.
Hierarchy
- class \Drupal\package_manager\Event\SandboxEvent implements \Symfony\Contracts\EventDispatcher\Event
- class \Drupal\package_manager\Event\SandboxValidationEvent implements \Drupal\package_manager\Event\SandboxEvent
- class \Drupal\package_manager\Event\PreCreateEvent implements \Drupal\package_manager\Event\SandboxValidationEvent
- class \Drupal\package_manager\Event\SandboxValidationEvent implements \Drupal\package_manager\Event\SandboxEvent
Expanded class hierarchy of PreCreateEvent
41 files declare their use of PreCreateEvent
- AllowedScaffoldPackagesValidator.php in core/
modules/ package_manager/ src/ Validator/ AllowedScaffoldPackagesValidator.php - AllowedScaffoldPackagesValidatorTest.php in core/
modules/ package_manager/ tests/ src/ Kernel/ AllowedScaffoldPackagesValidatorTest.php - BaseRequirementsFulfilledValidator.php in core/
modules/ package_manager/ src/ Validator/ BaseRequirementsFulfilledValidator.php - BaseRequirementsFulfilledValidatorTest.php in core/
modules/ package_manager/ tests/ src/ Kernel/ BaseRequirementsFulfilledValidatorTest.php - BaseRequirementValidatorTrait.php in core/
modules/ package_manager/ src/ Validator/ BaseRequirementValidatorTrait.php
File
-
core/
modules/ package_manager/ src/ Event/ PreCreateEvent.php, line 14
Namespace
Drupal\package_manager\EventView source
final class PreCreateEvent extends SandboxValidationEvent {
/**
* The list of paths to exclude from the stage directory.
*
* @var \Drupal\package_manager\ImmutablePathList
*/
public readonly ImmutablePathList $excludedPaths;
/**
* Constructs a PreCreateEvent object.
*
* @param \Drupal\package_manager\SandboxManagerBase $sandboxManager
* The stage which fired this event.
* @param \PhpTuf\ComposerStager\API\Path\Value\PathListInterface $excluded_paths
* The list of paths to exclude. These will not be copied into the stage
* directory when it is created.
*/
public function __construct(SandboxManagerBase $sandboxManager, PathListInterface $excluded_paths) {
parent::__construct($sandboxManager);
$this->excludedPaths = new ImmutablePathList($excluded_paths);
}
}
Members
Title Sort descending | Modifiers | Object type | Summary | Overriden Title | Overrides |
---|---|---|---|---|---|
PreCreateEvent::$excludedPaths | public | property | The list of paths to exclude from the stage directory. | ||
PreCreateEvent::__construct | public | function | Constructs a PreCreateEvent object. | Overrides SandboxEvent::__construct | |
SandboxValidationEvent::$results | protected | property | The validation results. | ||
SandboxValidationEvent::addError | public | function | Convenience method to flag a validation error. | ||
SandboxValidationEvent::addErrorFromThrowable | public | function | Convenience method, adds an error validation result from a throwable. | ||
SandboxValidationEvent::addResult | public | function | Adds a validation result to the event. | 1 | |
SandboxValidationEvent::getResults | public | function | Gets the validation results. | ||
SandboxValidationEvent::stopPropagation | public | function |
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.