function ContextDefinition::setDataType
Sets the data type needed by the context.
Parameters
string $data_type: The data type to set.
Return value
$this
Overrides ContextDefinitionInterface::setDataType
File
-
core/
lib/ Drupal/ Core/ Plugin/ Context/ ContextDefinition.php, line 132
Class
- ContextDefinition
- Defines a class for context definitions.
Namespace
Drupal\Core\Plugin\ContextCode
public function setDataType($data_type) {
$this->dataType = $data_type;
return $this;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.