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 |
|---|---|---|---|---|---|---|---|---|
| DateTimeIso8601 | class | Drupal\Core\TypedData\Plugin\DataType | core/ |
A data type for ISO 8601 date strings. | 3 | |||
| DateTimeIso8601Normalizer | class | Drupal\serialization\Normalizer | core/ |
Converts values for the DateTimeIso8601 data type to RFC3339. | 1 | 2 | ||
| DateTimeIso8601NormalizerTest | class | Drupal\Tests\serialization\Unit\Normalizer | core/ |
Unit test coverage for the "datetime_iso8601" @DataType. | ||||
| DateTimeIso8601NormalizerTestDrupalDateTime | class | Drupal\Tests\serialization\Unit\Normalizer | core/ |
Provides a test class for testing DrupalDateTime. | ||||
| DateTimeItem | class | Drupal\datetime\Plugin\Field\FieldType | core/ |
Plugin implementation of the 'datetime' field type. | 1 | 23 | ||
| DateTimeItemInterface | interface | Drupal\datetime\Plugin\Field\FieldType | core/ |
Interface definition for Datetime items. | 1 | 19 | ||
| DateTimeItemTest | class | Drupal\Tests\datetime\Kernel | core/ |
Tests the new entity API for the date field type. | ||||
| DateTimeNormalizer | class | Drupal\serialization\Normalizer | core/ |
Converts values for datetime objects to RFC3339 and from common formats. | 2 | 1 | ||
| DateTimeNormalizerTest | class | Drupal\Tests\serialization\Unit\Normalizer | core/ |
Unit test coverage for @DataTypes implementing DateTimeInterface. | ||||
| DateTimeNormalizerTestDrupalDateTime | class | Drupal\Tests\serialization\Unit\Normalizer | core/ |
Provides a test class for testing DrupalDateTime. | ||||
| DateTimePlainFormatter | class | Drupal\datetime\Plugin\Field\FieldFormatter | core/ |
Plugin implementation of the 'Plain' formatter for 'datetime' fields. | 1 | 1 | ||
| DateTimePlus | class | Drupal\Component\Datetime | core/ |
Wraps DateTime(). | 1 | 9 | ||
| DateTimePlusTest | class | Drupal\Tests\Component\Datetime | core/ |
Tests Drupal\Component\Datetime\DateTimePlus. | ||||
| DateTimeRangeConstantsInterface | in drupal:11.2.0 and is removed from drupal:12.0.0. Use enum DateTimeRangeDisplayOptions instead. |
interface | Drupal\datetime_range | core/ |
Declares constants used in the datetime range module. | |||
| DatetimeRangeHooks | class | Drupal\datetime_range\Hook | core/ |
Hook implementations for datetime_range. | ||||
| DatetimeRangeTestHooks | class | Drupal\datetime_range_test\Hook | core/ |
Hook implementations for datetime_range_test. | ||||
| DateTimeRangeTrait | trait | Drupal\datetime_range | core/ |
Provides friendly methods for datetime range. | 3 | |||
| DatetimeRangeViewsHooks | class | Drupal\datetime_range\Hook | core/ |
Hook implementations for datetime_range. | ||||
| DateTimeSchemaTest | class | Drupal\Tests\datetime\Kernel\Views | core/ |
Tests the Drupal\datetime\Plugin\views schemas. | ||||
| DateTimeTest | class | Drupal\Tests\system\Functional\System | core/ |
Test date formatting and time zone handling, including daylight saving time. | ||||
| DateTimeTimeAgoFormatter | class | Drupal\datetime\Plugin\Field\FieldFormatter | core/ |
Plugin implementation of the 'Time ago' formatter for 'datetime' fields. | ||||
| DateTimeTimeAgoFormatterTest | class | Drupal\Tests\datetime\Functional | core/ |
Tests the functionality of DateTimeTimeAgoFormatter field formatter. | ||||
| DateTimeViewsHelper | class | Drupal\datetime | core/ |
A helper for datetime fields integrating with views. | 2 | 2 | ||
| DatetimeViewsHooks | class | Drupal\datetime\Hook | core/ |
Hook implementations for datetime. | ||||
| DateTimeWidgetBase | class | Drupal\datetime\Plugin\Field\FieldWidget | core/ |
Base class for the 'datetime_*' widgets. | 3 | 1 | ||
| DateTimeWidgetTest | class | Drupal\Tests\datetime\Functional | core/ |
Tests Datetime widgets functionality. | ||||
| DayDate | class | Drupal\datetime\Plugin\views\argument | core/ |
Argument handler for a day. | ||||
| DayDate | class | Drupal\views\Plugin\views\argument | core/ |
Argument handler for a day (DD) | ||||
| DbCommandBase | class | Drupal\Core\Command | core/ |
Base command that abstracts handling of database connection arguments. | 3 | 1 | ||
| DbCommandBaseTest | class | Drupal\Tests\system\Kernel\Scripts | core/ |
Test that the DbToolsApplication works correctly. | ||||
| DbCommandBaseTester | class | Drupal\Tests\system\Kernel\Scripts | core/ |
Concrete command implementation for testing base features. | ||||
| DbDumpApplication | class | Drupal\Core\Command | core/ |
Provides a command to dump a database generation script. | 2 | |||
| DbDumpCommand | class | Drupal\Core\Command | core/ |
Provides a command to dump the current database to a script. | 1 | |||
| DbDumpCommandTest | class | Drupal\Tests\mysql\Kernel\mysql\Console | core/ |
Test that the DbDumpCommand works correctly. | ||||
| DbDumpTest | class | Drupal\Tests\mysql\Kernel\mysql | core/ |
Tests for the database dump commands. | ||||
| DbImportCommand | class | Drupal\Core\Command | core/ |
Provides a command to import the current database from a script. | 1 | |||
| DbImportCommandTest | class | Drupal\Tests\system\Kernel\Scripts | core/ |
Test that the DbImportCommand works correctly. | ||||
| DbLog | class | Drupal\dblog\Logger | core/ |
Logs events in the watchdog database table. | 2 | 2 | ||
| DblogClearLogConfirmForm | class | Drupal\dblog\Form | core/ |
Provides a confirmation form before clearing out the logs. | 1 | |||
| DbLogController | class | Drupal\dblog\Controller | core/ |
Returns responses for dblog routes. | 3 | |||
| DbLogControllerTest | class | Drupal\Tests\dblog\Kernel | core/ |
Tests for the DbLogController class. | ||||
| DblogFilterForm | class | Drupal\dblog\Form | core/ |
Provides the database logging filter form. | ||||
| DbLogFilters | class | Drupal\dblog | core/ |
Filter methods for the dblog module. | 4 | |||
| DbLogFormInjectionTest | class | Drupal\Tests\dblog\Kernel | core/ |
Tests serializing a form with an injected dblog logger instance. | ||||
| DblogHooks | class | Drupal\dblog\Hook | core/ |
Hook implementations for dblog. | ||||
| DblogMessage | class | Drupal\dblog\Plugin\views\field | core/ |
Provides a field handler that renders a log event with replaced variables. | ||||
| DblogOperations | class | Drupal\dblog\Plugin\views\field | core/ |
Provides a field handler that renders operation link markup. | ||||
| DbLogResource | class | Drupal\dblog\Plugin\rest\resource | core/ |
Provides a resource for database watchdog log entries. | ||||
| DbLogResourceTest | class | Drupal\Tests\dblog\Functional | core/ |
Tests the watchdog database log resource. | ||||
| DbLogTest | class | Drupal\Tests\dblog\Kernel | core/ |
Generate events and verify dblog entries. |
Pagination
- Previous page
- Page 48
- Next page
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.