TypedDataManagerInterface::getValidationConstraintManager

public TypedDataManagerInterface::getValidationConstraintManager() Gets the validation constraint manager. Return value \Drupal\Core\Validation\ConstraintManager The constraint manager. File core/lib/Drupal/Core/TypedData/TypedDataManagerInterface.php, line 187 Class TypedDataManagerInterface Defines an interface for typed data manager. Namespace Drupal\Core\TypedData Code public function getValidationConstraintManager();

TypedDataManagerInterface::setValidationConstraintManager

public TypedDataManagerInterface::setValidationConstraintManager(ConstraintManager $constraintManager) Sets the validation constraint manager. The validation constraint manager is used to instantiate validation constraint plugins. Parameters \Drupal\Core\Validation\ConstraintManager $constraintManager: The constraint manager to set. File core/lib/Drupal/Core/TypedData/TypedDataManagerInterface.php, line 198 Class TypedDataManagerInterface Defines an interface for typed data manager. Nam

TypedDataManagerInterface::getInstance

public TypedDataManagerInterface::getInstance(array $options) Parameters array $options: An array of options with the following keys: object: The parent typed data object, implementing the TypedDataInterface and either the ListInterface or the ComplexDataInterface. property: The name of the property to instantiate, or the delta of the the list item to instantiate. value: The value to set. If set, it has to match one of the supported data type formats as documented by the data type classes.

TypedDataManagerInterface::getValidator

public TypedDataManagerInterface::getValidator() Gets the validator for validating typed data. Return value \Symfony\Component\Validator\Validator\ValidatorInterface The validator object. File core/lib/Drupal/Core/TypedData/TypedDataManagerInterface.php, line 171 Class TypedDataManagerInterface Defines an interface for typed data manager. Namespace Drupal\Core\TypedData Code public function getValidator();

TypedDataManagerInterface::getCanonicalRepresentation

public TypedDataManagerInterface::getCanonicalRepresentation(TypedDataInterface $data) Gets the canonical representation of a TypedData object. The canonical representation is typically used when data is passed on to other code components. In many use cases, the TypedData object is mostly unified adapter wrapping a primary value (a string, an entity, etc.) which is the canonical representation that consuming code like constraint validators are really interested in. For some APIs, though, the do

TypedDataManagerInterface::createListDataDefinition

public TypedDataManagerInterface::createListDataDefinition($item_type) Creates a new list data definition for items of the given data type. Parameters string $item_type: The item type, for which a list data definition should be created. Return value \Drupal\Core\TypedData\ListDataDefinitionInterface A list definition for items of the given data type. See also \Drupal\Core\TypedData\TypedDataManager::createDataDefinition() File core/lib/Drupal/Core/TypedData/TypedDataManagerInterface.php, lin

TypedDataManagerInterface::createInstance

public TypedDataManagerInterface::createInstance($data_type, array $configuration = array()) Instantiates a typed data object. Parameters string $data_type: The data type, for which a typed object should be instantiated. array $configuration: The plugin configuration array, i.e. an array with the following keys: data_definition: The data definition object, i.e. an instance of \Drupal\Core\TypedData\DataDefinitionInterface. name: The name of the property or the delta of the list item if a pro

TypedDataManagerInterface::getDefaultConstraints

public TypedDataManagerInterface::getDefaultConstraints(DataDefinitionInterface $definition) Gets default constraints for the given data definition. This generates default constraint definitions based on the data definition; for example, a NotNull constraint is generated if the data is defined as required. Besides that, any constraints defined for the data type (that is, below the 'constraint' key of the type's plugin definition) are taken into account. Parameters \Drupal\Core\TypedData\DataDe

TypedDataManagerInterface

Defines an interface for typed data manager. Hierarchy interface \Drupal\Component\Plugin\PluginManagerInterface; interface \Drupal\Component\Plugin\Discovery\CachedDiscoveryInterfaceinterface \Drupal\Core\TypedData\TypedDataManagerInterface File core/lib/Drupal/Core/TypedData/TypedDataManagerInterface.php, line 13 Namespace Drupal\Core\TypedData Members Name Modifiers Type Description CachedDiscoveryInterface::clearCachedDefinitions public function Clears static and pe

TypedDataManagerInterface::createDataDefinition

public TypedDataManagerInterface::createDataDefinition($data_type) Creates a new data definition object. While data definitions objects may be created directly if the definition class used by a data type is known, this method allows the creation of data definitions for any given data type. For example, if a definition for a map is to be created, the following code could be used instead of calling this method with the argument 'map': $map_definition = \Drupal\Core\TypedData\MapDataDefinition::