Classes, traits, and interfaces in Drupal 9
Primary tabs
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
|
Name |
Type | Namespace | Location | Description | Direct uses | Use statements | Strings |
|---|---|---|---|---|---|---|---|
| AddRoleUser | class |
Drupal\ |
core/ |
Adds a role to a user. | 1 | ||
| AddRoleUserTest | class |
Drupal\ |
core/ |
@coversDefaultClass \Drupal\user\Plugin\Action\AddRoleUser @group user | |||
| AddSectionController | class |
Drupal\ |
core/ |
Defines a controller to add a new section. | |||
| AddStyleSheetCommand | class |
Drupal\ |
core/ |
AJAX command to add style sheets to a CKEditor instance. | 1 | ||
| AdminContext | class |
Drupal\ |
core/ |
Provides a helper class to determine whether the route is an admin one. | 5 | 2 | |
| AdminController | class |
Drupal\ |
core/ |
Controller for admin section. | |||
| AdminDemoNegotiator | class |
Drupal\ |
core/ |
Negotiates the theme for the block admin demo page via the URL. | 2 | ||
| AdminHtmlRouteProvider | class |
Drupal\ |
core/ |
Provides HTML routes for entities with administrative add/edit/delete pages. | 3 | 4 | |
| AdminMetaTagTest | class |
Drupal\ |
core/ |
Confirm that the fingerprinting meta tag appears as expected. | |||
| AdminNegotiator | class |
Drupal\ |
core/ |
Sets the active theme on admin pages. | 1 | 2 | |
| AdminNegotiatorTest | class |
Drupal\ |
core/ |
Tests AdminNegotiator class. | |||
| AdminPathConfigEntityConverter | class |
Drupal\ |
core/ |
Makes sure the unmodified ConfigEntity is loaded on admin pages. | 1 | 1 | 2 |
| AdminPathConfigEntityConverter | class |
Drupal\ |
core/ |
Provides a proxy class for \Drupal\Core\ParamConverter\AdminPathConfigEntityConverter. | |||
| AdminPathEntityConverterLanguageTest | class |
Drupal\ |
core/ |
Test administration path based conversion of entities. | 1 | 1 | |
| AdminRouteSubscriber | class |
Drupal\ |
core/ |
Adds the _admin_route option to each admin HTML route. | 1 | 2 | |
| AdminRouteSubscriberTest | class |
Drupal\ |
core/ |
@coversDefaultClass \Drupal\system\EventSubscriber\AdminRouteSubscriber @group system | |||
| AdminTest | class |
Drupal\ |
core/ |
Tests output on administrative pages and compact mode functionality. | |||
| AdvancedSettingsForm | class |
Drupal\ |
core/ |
Form builder for the advanced admin settings page. | 1 | ||
| AdvisoriesConfigSubscriber | class |
Drupal\ |
core/ |
Defines a config subscriber for changes to 'system.advisories'. | 2 | ||
| AdvisoriesTestHttpClient | class |
Drupal\ |
core/ |
Provides a decorator service for the 'http_client' service for testing. | 1 | 2 | |
| AdvisoriesUpdatePathTest | class |
Drupal\ |
core/ |
Tests advisories settings update path. | |||
| AdvisoryTestController | class |
Drupal\ |
core/ |
Defines a controller to return JSON for security advisory tests. | |||
| AfterCommand | class |
Drupal\ |
core/ |
An AJAX command for calling the jQuery after() method. | 2 | ||
| AggregatorAdminTest | class |
Drupal\ |
core/ |
Tests aggregator admin pages. | |||
| AggregatorController | class |
Drupal\ |
core/ |
Returns responses for aggregator module routes. | |||
| AggregatorCronTest | class |
Drupal\ |
core/ |
Update feeds on cron. | |||
| AggregatorDisplayConfigurableTest | class |
Drupal\ |
core/ |
Tests making aggregator_feed and aggregator_item base fields' displays configurable. | |||
| AggregatorFeed | class |
Drupal\ |
core/ |
Drupal 6/7 feed source from database. | |||
| AggregatorFeedBlock | class |
Drupal\ |
core/ |
Provides an 'Aggregator feed' block with the latest items from the feed. | |||
| AggregatorFeedTest | class |
Drupal\ |
core/ |
Tests D6 aggregator feed source plugin. | |||
| AggregatorFeedViewsData | class |
Drupal\ |
core/ |
Provides the views data for the aggregator feed entity type. | |||
| AggregatorFeedViewsFieldAccessTest | class |
Drupal\ |
core/ |
Tests base field access in Views for the aggregator_feed entity. | |||
| AggregatorFetcher | class |
Drupal\ |
core/ |
Defines a Plugin annotation object for aggregator fetcher plugins. | |||
| AggregatorItem | class |
Drupal\ |
core/ |
Drupal 6/7 aggregator item source from database. | |||
| AggregatorItemTest | class |
Drupal\ |
core/ |
Tests aggregator item source plugin. | |||
| AggregatorItemViewsData | class |
Drupal\ |
core/ |
Provides the views data for the aggregator item entity type. | |||
| AggregatorItemViewsFieldAccessTest | class |
Drupal\ |
core/ |
Tests base field access in Views for the aggregator_item entity. | |||
| AggregatorLocalTasksTest | class |
Drupal\ |
core/ |
Tests existence of aggregator local tasks. | |||
| AggregatorParser | class |
Drupal\ |
core/ |
Defines a Plugin annotation object for aggregator parser plugins. | |||
| AggregatorPluginManager | class |
Drupal\ |
core/ |
Manages aggregator plugins. | 2 | 4 | |
| AggregatorPluginManagerTest | class |
Drupal\ |
core/ |
Tests the aggregator plugin manager. | |||
| AggregatorPluginSettingsBase | abstract class |
Drupal\ |
core/ |
Base class for aggregator plugins that implement settings forms. | 2 | 2 | |
| AggregatorPluginSettingsBaseTest | class |
Drupal\ |
core/ |
Tests settings configuration of individual aggregator plugins. | |||
| AggregatorProcessor | class |
Drupal\ |
core/ |
Defines a Plugin annotation object for aggregator processor plugins. | |||
| AggregatorRefresh | class |
Drupal\ |
core/ |
Updates a feed's items. | |||
| AggregatorRenderingTest | class |
Drupal\ |
core/ |
Tests display of aggregator items on the page. | |||
| AggregatorTestBase | abstract class |
Drupal\ |
core/ |
Defines a base class for testing the Aggregator module. | 15 | ||
| AggregatorTestRssController | class |
Drupal\ |
core/ |
Controller for the aggregator_test module. | |||
| AggregatorTitleFormatter | class |
Drupal\ |
core/ |
Plugin implementation of the 'aggregator_title' formatter. | |||
| AggregatorTitleTest | class |
Drupal\ |
core/ |
Tests the aggregator_title formatter. |