class TypedDataInternalPropertiesHelper in Drupal 10
Same name and namespace in other branches
- 8 core/lib/Drupal/Core/TypedData/TypedDataInternalPropertiesHelper.php \Drupal\Core\TypedData\TypedDataInternalPropertiesHelper
- 9 core/lib/Drupal/Core/TypedData/TypedDataInternalPropertiesHelper.php \Drupal\Core\TypedData\TypedDataInternalPropertiesHelper
Helper class for internal properties.
Hierarchy
- class \Drupal\Core\TypedData\TypedDataInternalPropertiesHelper
Expanded class hierarchy of TypedDataInternalPropertiesHelper
3 files declare their use of TypedDataInternalPropertiesHelper
- ResourceIdentifier.php in core/
modules/ jsonapi/ src/ JsonApiResource/ ResourceIdentifier.php - ResourceObject.php in core/
modules/ jsonapi/ src/ JsonApiResource/ ResourceObject.php - ResourceTestBase.php in core/
modules/ jsonapi/ tests/ src/ Functional/ ResourceTestBase.php
File
- core/
lib/ Drupal/ Core/ TypedData/ TypedDataInternalPropertiesHelper.php, line 8
Namespace
Drupal\Core\TypedDataView source
class TypedDataInternalPropertiesHelper {
/**
* Gets an array non-internal properties from a complex data object.
*
* @param \Drupal\Core\TypedData\ComplexDataInterface $data
* The complex data object.
*
* @return \Drupal\Core\TypedData\TypedDataInterface[]
* The non-internal properties, keyed by property name.
*/
public static function getNonInternalProperties(ComplexDataInterface $data) {
return array_filter($data
->getProperties(TRUE), function (TypedDataInterface $property) {
return !$property
->getDataDefinition()
->isInternal();
});
}
}