Classes, traits, and interfaces - main - 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 1529
| Name | Deprecated | Object type | Namespace | File name | Summary | Direct uses | Use statements | Strings |
|---|---|---|---|---|---|---|---|---|
| TestHelpTopicPlugin | class | Drupal\help_topics_test\Plugin\HelpTopic | core/ |
A fake help topic plugin for testing. | 1 | |||
| TestHookAfter | class | Drupal\aaa_hook_collector_test\Hook | core/ |
This class contains hook implementations. | ||||
| TestHookAfter | class | Drupal\bbb_hook_collector_test\Hook | core/ |
This class contains hook implementations. | ||||
| TestHookAfterClassMethod | class | Drupal\aaa_hook_collector_test\Hook | core/ |
This class contains hook implementations. | ||||
| TestHookAfterClassMethod | class | Drupal\bbb_hook_collector_test\Hook | core/ |
This class contains hook implementations. | 1 | |||
| TestHookBefore | class | Drupal\aaa_hook_collector_test\Hook | core/ |
This class contains hook implementations. | ||||
| TestHookBefore | class | Drupal\bbb_hook_collector_test\Hook | core/ |
This class contains hook implementations. | ||||
| TestHookClass | class | Drupal\Tests\Core\Extension | core/ |
Class used to test ModuleHandler::hasImplementations() | ||||
| TestHookCollectionHooks | class | Drupal\oop_hook_theme\Hook | core/ |
Contains hooks for testing hook collection. | ||||
| TestHookFirst | class | Drupal\aaa_hook_collector_test\Hook | core/ |
This class contains hook implementations. | ||||
| TestHookFirst | class | Drupal\bbb_hook_collector_test\Hook | core/ |
This class contains hook implementations. | ||||
| TestHookLast | class | Drupal\aaa_hook_collector_test\Hook | core/ |
This class contains hook implementations. | ||||
| TestHookLast | class | Drupal\bbb_hook_collector_test\Hook | core/ |
This class contains hook implementations. | ||||
| TestHookOrderExtraTypes | class | Drupal\aaa_hook_collector_test\Hook | core/ |
This class contains hook implementations. | ||||
| TestHookOrderExtraTypes | class | Drupal\bbb_hook_collector_test\Hook | core/ |
This class contains hook implementations. | ||||
| TestHookRemove | class | Drupal\hook_test_remove\Hook | core/ |
Add a hook here, then remove it with another attribute. | ||||
| TestHookReorderHookFirst | class | Drupal\aaa_hook_collector_test\Hook | core/ |
This class contains hook implementations. | ||||
| TestHookReorderHookLast | class | Drupal\bbb_hook_collector_test\Hook | core/ |
This class contains hook implementations. | 1 | |||
| TestHtmlBlock | class | Drupal\block_test\Plugin\Block | core/ |
Provides a block to test HTML. | 1 | |||
| TestHtmlMailCollector | class | Drupal\mail_html_test\Plugin\Mail | core/ |
Defines a mail backend that captures sent HTML messages in the state system. | ||||
| TestHtmxHooks | class | Drupal\test_htmx\Hook | core/ |
Hooks for the test_htmx module. | ||||
| TestHttpClientMiddleware | class | Drupal\Core\Test\HttpClientMiddleware | core/ |
Overrides the User-Agent HTTP header for outbound HTTP requests. | 1 | |||
| TestHttpMiddlewareClass | class | Drupal\Tests\Core\DependencyInjection\Fixture | core/ |
Stub of http_middleware class. | 1 | |||
| TestingHooksProfile | class | Drupal\testing_hooks\Hook | core/ |
Hook implementation on behalf of another module. | ||||
| TestingProfileHooksTest | class | Drupal\FunctionalTests\Installer | core/ |
Tests installing the Testing profile with update notifications on. | ||||
| TestingProfileInstallTest | class | Drupal\FunctionalTests\Installer | core/ |
Tests installing the Testing profile with update notifications on. | ||||
| TestingRequirementsRequirements | class | Drupal\testing_requirements\Install\Requirements | core/ |
Install time requirements for the testing_requirements module. | ||||
| TestingSiteConfigHooks | class | Drupal\testing_site_config\Hook | core/ |
Simulates a hook class with a dependency chain requiring the kernel. | ||||
| TestInjection | class | Drupal\services_defaults_test | core/ |
A service that is injected via default autowiring. | 2 | |||
| TestInjection | class | Drupal\autowire_test | core/ |
A service that is autowired. | 1 | 1 | ||
| TestInjection2 | class | Drupal\autowire_test | core/ |
A service that is autowired. | 1 | |||
| TestInjection2 | class | Drupal\services_defaults_test | core/ |
A service that is injected via default autowiring. | ||||
| TestInjection3 | class | Drupal\autowire_test | core/ |
A service that is autowired. | 1 | |||
| TestInjectionInterface | interface | Drupal\services_defaults_test | core/ |
An interface for a service that is injected via default autowiring. | 1 | |||
| TestInjectionInterface | interface | Drupal\autowire_test | core/ |
An interface for a service that is autowired. | 2 | |||
| TestInlineTemplateFormBlock | class | Drupal\layout_builder_form_block_test\Plugin\Block | core/ |
Provides a block containing inline template with <form> tag. | ||||
| TestInstallerThemeHooks | class | Drupal\test_installer_theme\Hook | core/ |
Form alter hooks for installer tests. | ||||
| TestInstallStorage | class | Drupal\config_test | core/ |
Tests configuration of profiles, modules and themes. | 1 | |||
| TestInterface | interface | Drupal\Tests\Core\DependencyInjection | core/ |
A test interface for testing ContainerBuilder::__construct(). | ||||
| TestInterface | interface | Drupal\Tests\Component\ProxyBuilder | core/ |
Test interface. | 1 | |||
| TestInvalidHookCollectionHooks | class | Drupal\oop_hook_theme_with_module\Hook | core/ |
Contains hooks that will throw exceptions during collection. | ||||
| TestInvalidHookCollectionHooks | class | Drupal\oop_hook_theme_with_remove\Hook | core/ |
Contains hooks that will throw exceptions during collection. | ||||
| TestInvalidHookCollectionHooks | class | Drupal\oop_hook_theme_with_order\Hook | core/ |
Contains hooks that will throw exceptions during collection. | ||||
| TestInvalidHookCollectionHooks | class | Drupal\oop_hook_theme_with_reorder\Hook | core/ |
Contains hooks that will throw exceptions during collection. | ||||
| TestItem | class | Drupal\field_test\Plugin\Field\FieldType | core/ |
Defines the 'test_field' entity field item. | 5 | |||
| TestItemTest | class | Drupal\Tests\field\Kernel | core/ |
Tests the new entity API for the test field type. | ||||
| TestItemWithDependencies | class | Drupal\field_test\Plugin\Field\FieldType | core/ |
Defines the 'test_field_with_dependencies' entity field item. | ||||
| TestItemWithDependenciesTest | class | Drupal\Tests\field\Kernel | core/ |
Tests the new entity API for the test field with dependencies type. | ||||
| TestItemWithMultipleDescriptions | class | Drupal\field_test\Plugin\Field\FieldType | core/ |
Defines the 'test_field_with_multiple_descriptions' entity field item. | ||||
| TestItemWithPreconfiguredOptions | class | Drupal\field_test\Plugin\Field\FieldType | core/ |
Defines the 'test_field_with_preconfigured_options' entity field item. |
Pagination
- Previous page
- Page 192
- Next page
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.