Classes, traits, and interfaces - 10.3.x - drupal
Introduction to classes
A lot of the PHP code in Drupal is object oriented (OO), making use of PHP classes, interfaces, and traits. See the Objected-oriented programming conventions for more information.
See also
Objected-oriented programming conventions
File
-
core/
core.api.php, line 1518
| Name | Deprecated | Object type | Namespace | File name | Summary | Direct uses | Use statements | Strings |
|---|---|---|---|---|---|---|---|---|
| TypedConfigTest | class | Drupal\KernelTests\Config | core/ |
Tests config validation mechanism. | ||||
| TypedData | abstract class | Drupal\Core\TypedData | core/ |
The abstract base class for typed data. | 14 | 13 | ||
| TypedDataAwareValidatorTrait | trait | Drupal\Core\TypedData\Validation | core/ |
Defines a trait to access the typed data object of a validated value. | 5 | |||
| TypedDataCacheableDependencyInterface | interface | Drupal\Tests\Core\Plugin\Context | core/ |
Test interface used for mocking. | ||||
| TypedDataDefinitionEntityBundleTest | class | Drupal\KernelTests\Core\TypedData | core/ |
Tests data type metadata for entity bundles. | ||||
| TypedDataDefinitionTest | class | Drupal\KernelTests\Core\TypedData | core/ |
Tests deriving metadata of core data types. | ||||
| TypedDataInterface | interface | Drupal\Core\TypedData | core/ |
Interface for typed data objects. | 3 | 32 | ||
| TypedDataInternalPropertiesHelper | class | Drupal\Core\TypedData | core/ |
Helper class for internal properties. | 6 | |||
| TypedDataManager | class | Drupal\Core\TypedData | core/ |
Manages data type plugins. | 1 | 7 | 2 | |
| TypedDataManagerInterface | interface | Drupal\Core\TypedData | core/ |
Defines an interface for typed data manager. | 2 | 27 | ||
| TypedDataMetadata | class | Drupal\Core\TypedData\Validation | core/ |
Validator metadata for typed data objects. | ||||
| TypedDataNormalizer | class | Drupal\serialization\Normalizer | core/ |
Converts typed data objects to arrays. | 1 | 2 | ||
| TypedDataNormalizerTest | class | Drupal\Tests\serialization\Unit\Normalizer | core/ |
@coversDefaultClass \Drupal\serialization\Normalizer\TypedDataNormalizer[[api-linebreak]] @group serialization | ||||
| TypedDataStringBlock | class | Drupal\plugin_test\Plugin\plugin_test\mock_block | core/ |
Implements a String TypedData contextual block plugin. | ||||
| TypedDataTest | class | Drupal\KernelTests\Core\TypedData | core/ |
Tests the functionality of all core data types. | ||||
| TypedDataTrait | trait | Drupal\Core\TypedData | core/ |
Wrapper methods for classes that needs typed data manager object. | 2 | |||
| TypeResolver | class | Drupal\Core\Config\Schema | core/ |
Provides helper methods for resolving config schema types. | 3 | |||
| TypeResolverTest | class | Drupal\Tests\Core\Config | core/ |
@covers \Drupal\Core\Config\Schema\TypeResolver[[api-linebreak]] @group config | ||||
| Uid | class | Drupal\user\Plugin\views\argument | core/ |
Argument handler to accept a user id. | 1 | 1 | ||
| UidRevision | class | Drupal\node\Plugin\views\filter | core/ |
Filter handler to check for revisions a certain user has created. | ||||
| UidRevision | class | Drupal\node\Plugin\views\argument | core/ |
Filter handler, accepts a user ID. | ||||
| UiHelperTrait | trait | Drupal\Tests | core/ |
Provides UI helper methods. | ||||
| UITestBase | abstract class | Drupal\Tests\views_ui\Functional | core/ |
Provides a base class for testing the Views UI. | 44 | 5 | ||
| UmamiMultilingualInstallTest | class | Drupal\Tests\demo_umami\Functional | core/ |
Tests the multilingual installer installing the Umami profile. | ||||
| UnapprovedComments | class | Drupal\comment\Plugin\Menu\LocalTask | core/ |
Provides a local task that shows the amount of unapproved comments. | 1 | |||
| UnblockUser | class | Drupal\user\Plugin\Action | core/ |
Unblocks a user. | ||||
| UncacheableDependencyTrait | trait | Drupal\Core\Cache | core/ |
Trait to implement CacheableDependencyInterface for uncacheable objects. | 3 | |||
| UncacheableFieldHandlerTrait | trait | Drupal\views\Plugin\views\field | core/ |
Trait encapsulating the logic for uncacheable field handlers. | 1 | |||
| UncacheableTestAccessResult | class | Drupal\Tests\Core\Access | core/ |
|||||
| UncaughtExceptionTest | class | Drupal\FunctionalTests\Bootstrap | core/ |
Tests kernel panic when things are really messed up. | ||||
| UnchangingCacheableDependencyTrait | trait | Drupal\Core\Cache | core/ |
Trait to implement CacheableDependencyInterface for unchanging objects. | 4 | |||
| Undefined | class | Drupal\Core\Config\Schema | core/ |
Undefined configuration element. | 3 | 1 | ||
| UndefinedLinkTemplateException | class | Drupal\Core\Entity\Exception | core/ |
Defines an exception class for undefined link templates. | 4 | |||
| UnformattedSummary | class | Drupal\views\Plugin\views\style | core/ |
The default style plugin for summaries. | ||||
| Unicode | class | Drupal\Component\Utility | core/ |
Provides Unicode-related conversions and operations. | 50 | |||
| UnicodeTest | class | Drupal\Tests\Component\Utility | core/ |
Test unicode handling features implemented in Unicode component. | ||||
| UnicornEditor | class | Drupal\editor_test\Plugin\Editor | core/ |
Defines a Unicorn-powered text editor for Drupal (for testing purposes). | ||||
| UninstallDefaultContentTest | class | Drupal\Tests\demo_umami_content\Functional | core/ |
Tests that uninstalling default content removes created content. | ||||
| UninstalledExtensionException | class | Drupal\Core\Extension\Exception | core/ |
Exception class thrown when a specified extension has not been installed. | ||||
| UninstallKernelTest | class | Drupal\Tests\system\Kernel\Installer | core/ |
Tests the uninstallation of modules. | ||||
| UninstallTest | class | Drupal\Tests\system\Functional\Module | core/ |
Tests the uninstallation of modules. | ||||
| UniqueFieldConstraint | class | Drupal\Core\Validation\Plugin\Validation\Constraint | core/ |
Checks if an entity field has a unique value. | 3 | 4 | ||
| UniqueFieldConstraintTest | class | Drupal\KernelTests\Core\Validation | core/ |
Tests the unique field value validation constraint. | ||||
| UniqueFieldValueValidator | class | Drupal\Core\Validation\Plugin\Validation\Constraint | core/ |
Validates that a field is unique for the given entity type. | 1 | |||
| UniqueLabelInListConstraint | class | Drupal\ckeditor5\Plugin\Validation\Constraint | core/ |
Uniquely labeled list item constraint. | ||||
| UniqueLabelInListConstraintValidator | class | Drupal\ckeditor5\Plugin\Validation\Constraint | core/ |
Uniquely labeled list item constraint validator. | ||||
| UniquePathAliasConstraint | class | Drupal\Core\Path\Plugin\Validation\Constraint | core/ |
Validation constraint for unique path alias values. | ||||
| UniquePathAliasConstraintValidator | class | Drupal\Core\Path\Plugin\Validation\Constraint | core/ |
Constraint validator for a unique path alias. | ||||
| UniqueValuesConstraintValidatorTest | class | Drupal\KernelTests\Core\Validation | core/ |
Tests the unique field value validation constraint. | ||||
| UnitTestCase | abstract class | Drupal\Tests | core/ |
Provides a base class and helpers for Drupal unit tests. | 667 | 665 |
Pagination
- Previous page
- Page 184
- Next page
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.