8.5.x ContextAwarePluginInterface.php ContextAwarePluginInterface::getContexts()
8.0.x ContextAwarePluginInterface.php ContextAwarePluginInterface::getContexts()
8.1.x ContextAwarePluginInterface.php ContextAwarePluginInterface::getContexts()
8.2.x ContextAwarePluginInterface.php ContextAwarePluginInterface::getContexts()
8.3.x ContextAwarePluginInterface.php ContextAwarePluginInterface::getContexts()
8.4.x ContextAwarePluginInterface.php ContextAwarePluginInterface::getContexts()
8.6.x ContextAwarePluginInterface.php ContextAwarePluginInterface::getContexts()

Gets the defined contexts.

Return value

array The set context objects.

Throws

\Drupal\Component\Plugin\Exception\PluginException If contexts are defined but not set.

1 method overrides ContextAwarePluginInterface::getContexts()
ContextAwarePluginBase::getContexts in core/lib/Drupal/Component/Plugin/ContextAwarePluginBase.php
Gets the defined contexts.

File

core/lib/Drupal/Component/Plugin/ContextAwarePluginInterface.php, line 48

Class

ContextAwarePluginInterface
Interface for defining context aware plugins.

Namespace

Drupal\Component\Plugin

Code

public function getContexts();