function hook_data_type_info_alter
Same name in other branches
- 9 core/core.api.php \hook_data_type_info_alter()
- 10 core/core.api.php \hook_data_type_info_alter()
- 11.x core/core.api.php \hook_data_type_info_alter()
Alter available data types for typed data wrappers.
Parameters
array $data_types: An array of data type information.
See also
hook_data_type_info()
Related topics
1 invocation of hook_data_type_info_alter()
- TypedDataManager::__construct in core/
lib/ Drupal/ Core/ TypedData/ TypedDataManager.php - Constructs a new TypedDataManager.
File
-
core/
core.api.php, line 1956
Code
function hook_data_type_info_alter(&$data_types) {
$data_types['email']['class'] = '\\Drupal\\mymodule\\Type\\Email';
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.