public function DataProducerPluginBase::getContextDefinitions in GraphQL 8.4
Return value
\Drupal\Core\Plugin\Context\ContextDefinitionInterface[]
Overrides ContextAwarePluginBase::getContextDefinitions
1 call to DataProducerPluginBase::getContextDefinitions()
- DataProducerPluginBase::getContextDefinition in src/
Plugin/ GraphQL/ DataProducer/ DataProducerPluginBase.php
File
- src/
Plugin/ GraphQL/ DataProducer/ DataProducerPluginBase.php, line 19
Class
- DataProducerPluginBase
- Base class for data producers that resolve fields for queries or mutations.
Namespace
Drupal\graphql\Plugin\GraphQL\DataProducerCode
public function getContextDefinitions() {
$definition = $this
->getPluginDefinition();
return !empty($definition['consumes']) ? $definition['consumes'] : [];
}