class EntityPublishedActionDeriver in Drupal 8
Same name and namespace in other branches
- 9 core/lib/Drupal/Core/Action/Plugin/Action/Derivative/EntityPublishedActionDeriver.php \Drupal\Core\Action\Plugin\Action\Derivative\EntityPublishedActionDeriver
- 10 core/lib/Drupal/Core/Action/Plugin/Action/Derivative/EntityPublishedActionDeriver.php \Drupal\Core\Action\Plugin\Action\Derivative\EntityPublishedActionDeriver
Provides an action deriver that finds publishable entity types.
Hierarchy
- class \Drupal\Component\Plugin\Derivative\DeriverBase implements DeriverInterface
- class \Drupal\Core\Action\Plugin\Action\Derivative\EntityActionDeriverBase implements ContainerDeriverInterface uses StringTranslationTrait
- class \Drupal\Core\Action\Plugin\Action\Derivative\EntityPublishedActionDeriver
- class \Drupal\Core\Action\Plugin\Action\Derivative\EntityActionDeriverBase implements ContainerDeriverInterface uses StringTranslationTrait
Expanded class hierarchy of EntityPublishedActionDeriver
See also
\Drupal\Core\Action\Plugin\Action\PublishAction
\Drupal\Core\Action\Plugin\Action\UnpublishAction
1 file declares its use of EntityPublishedActionDeriver
- PublishActionTest.php in core/
tests/ Drupal/ KernelTests/ Core/ Action/ PublishActionTest.php
File
- core/
lib/ Drupal/ Core/ Action/ Plugin/ Action/ Derivative/ EntityPublishedActionDeriver.php, line 14
Namespace
Drupal\Core\Action\Plugin\Action\DerivativeView source
class EntityPublishedActionDeriver extends EntityActionDeriverBase {
/**
* {@inheritdoc}
*/
protected function isApplicable(EntityTypeInterface $entity_type) {
return $entity_type
->entityClassImplements(EntityPublishedInterface::class);
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
DeriverBase:: |
protected | property | List of derivative definitions. | 1 |
DeriverBase:: |
public | function |
Gets the definition of a derivative plugin. Overrides DeriverInterface:: |
|
EntityActionDeriverBase:: |
protected | property | The entity type manager. | |
EntityActionDeriverBase:: |
public static | function |
Creates a new class instance. Overrides ContainerDeriverInterface:: |
|
EntityActionDeriverBase:: |
protected | function | Gets a list of applicable entity types. | |
EntityActionDeriverBase:: |
public | function |
Gets the definition of all derivatives of a base plugin. Overrides DeriverBase:: |
1 |
EntityActionDeriverBase:: |
public | function | Constructs a new EntityActionDeriverBase object. | |
EntityPublishedActionDeriver:: |
protected | function |
Indicates whether the deriver can be used for the provided entity type. Overrides EntityActionDeriverBase:: |
|
StringTranslationTrait:: |
protected | property | The string translation service. | 1 |
StringTranslationTrait:: |
protected | function | Formats a string containing a count of items. | |
StringTranslationTrait:: |
protected | function | Returns the number of plurals supported by a given language. | |
StringTranslationTrait:: |
protected | function | Gets the string translation service. | |
StringTranslationTrait:: |
public | function | Sets the string translation service to use. | 2 |
StringTranslationTrait:: |
protected | function | Translates a string to the current language or to a given language. |