Classes, traits, and interfaces in Drupal 10
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 |
|---|---|---|---|---|---|---|---|
| BooleanItemTest | class |
Drupal\ |
core/ |
Tests the new entity API for the boolean field type. | |||
| BooleanOperatorString | class |
Drupal\ |
core/ |
Simple filter to handle matching of boolean values. | |||
| BootstrapConfigStorageFactory | class |
Drupal\ |
core/ |
Defines a factory for retrieving the config storage used pre-kernel. | 2 | ||
| Box | class |
Drupal\ |
core/ |
Drupal 6 block source from database. | |||
| BoxTest | class |
Drupal\ |
core/ |
Tests D6 block boxes source plugin. | |||
| BoxTranslation | class |
Drupal\ |
core/ |
Drupal 6 i18n custom block translations source from database. | |||
| BoxTranslationTest | class |
Drupal\ |
core/ |
Tests i18n custom block translations source plugin. | |||
| Breadcrumb | class |
Drupal\ |
core/ |
Used to return generated breadcrumbs with associated cacheability metadata. | 12 | ||
| Breadcrumb404Test | class |
Drupal\ |
core/ |
Tests the breadcrumb of 404 pages. | |||
| BreadcrumbBuilderInterface | interface |
Drupal\ |
core/ |
Defines an interface for classes that build breadcrumbs. | 7 | 7 | |
| BreadcrumbFrontCacheContextsTest | class |
Drupal\ |
core/ |
Tests breadcrumbs functionality. | |||
| BreadcrumbManager | class |
Drupal\ |
core/ |
Provides a breadcrumb manager. | 1 | 2 | |
| BreadcrumbManagerTest | class |
Drupal\ |
core/ |
@coversDefaultClass \Drupal\Core\Breadcrumb\BreadcrumbManager @group Breadcrumb | |||
| BreadcrumbTest | class |
Drupal\ |
core/ |
@coversDefaultClass \Drupal\Core\Breadcrumb\Breadcrumb @group Breadcrumb | |||
| BreadcrumbTest | class |
Drupal\ |
core/ |
Tests breadcrumbs functionality. | |||
| BreakLockForm | class |
Drupal\ |
core/ |
Builds the form to break the lock of an edited view. | |||
| BreakLockLink | class |
Drupal\ |
core/ |
Provides a link to break a tempstore lock. | |||
| Breakpoint | class |
Drupal\ |
core/ |
Default object used for breakpoint plugins. | 1 | ||
| BreakpointDiscoveryTest | class |
Drupal\ |
core/ |
Tests discovery of breakpoints provided by themes and modules. | |||
| BreakpointInterface | interface |
Drupal\ |
core/ |
Interface for Breakpoint plugins. | 1 | 1 | |
| BreakpointManager | class |
Drupal\ |
core/ |
Defines a breakpoint plugin manager to deal with breakpoints. | 2 | ||
| BreakpointManagerInterface | interface |
Drupal\ |
core/ |
Defines an interface for breakpoint managers. | 1 | 1 | |
| BreakpointTest | class |
Drupal\ |
core/ |
@coversDefaultClass \Drupal\breakpoint\Breakpoint @group Breakpoint | |||
| Broccoli | class |
Drupal\ |
core/ |
Plugin annotation @Plugin( id = "broccoli", label = "Broccoli", color = "green" ) | 1 | ||
| Broken | class |
Drupal\ |
core/ |
Defines a fallback plugin for missing block plugins. | 1 | ||
| Broken | class |
Drupal\ |
core/ |
Defines a fallback plugin for missing entity_reference selection plugins. | |||
| Broken | class |
Drupal\ |
core/ |
A special handler to take the place of missing or broken handlers. | 1 | ||
| Broken | class |
Drupal\ |
core/ |
A special handler to take the place of missing or broken handlers. | |||
| Broken | class |
Drupal\ |
core/ |
A special handler to take the place of missing or broken handlers. | 2 | ||
| Broken | class |
Drupal\ |
core/ |
A special handler to take the place of missing or broken handlers. | |||
| Broken | class |
Drupal\ |
core/ |
A special handler to take the place of missing or broken handlers. | |||
| Broken | class |
Drupal\ |
core/ |
A special handler to take the place of missing or broken handlers. | 1 | ||
| BrokenCacheUpdateTest | class |
Drupal\ |
core/ |
Ensures that a broken or out-of-date element info cache is not used. | |||
| BrokenHandlerTrait | trait |
Drupal\ |
core/ |
A Trait for Views broken handlers. | 6 | ||
| BrokenInboundPathProcessor | class |
Drupal\ |
core/ |
Example path processor which breaks on inbound. | 2 | ||
| BrokenPostRequestException | class |
Drupal\ |
core/ |
Defines an exception used, when the POST HTTP body is broken. | 4 | ||
| BrokenToolkit | class |
Drupal\ |
core/ |
Defines a Test toolkit for image manipulation within Drupal. | |||
| BrowserHtmlDebugTrait | trait |
Drupal\ |
core/ |
Provides the debug functions for browser tests. | |||
| BrowserMissingDependentModuleMethodTest | class |
Drupal\ |
core/ |
A fixture test class with requires annotation. | 1 | ||
| BrowserMissingDependentModuleTest | class |
Drupal\ |
core/ |
A fixture test class with requires annotation. | 1 | ||
| BrowserTestBase | abstract class |
Drupal\ |
core/ |
Provides a test case for functional Drupal tests. | 542 | 547 | |
| BrowserTestBaseTest | class |
Drupal\ |
core/ |
Tests BrowserTestBase functionality. | |||
| BrowserTestBaseTest | class |
Drupal\ |
core/ |
@coversDefaultClass \Drupal\Tests\BrowserTestBase @group Test | |||
| BrowserTestBaseTest | class |
Drupal\ |
core/ |
@group Test @group FunctionalTests | |||
| BrowserTestBaseUserAgentTest | class |
Drupal\ |
core/ |
Tests BrowserTestBase functionality. | |||
| BrowserWithJavascriptTest | class |
Drupal\ |
core/ |
Tests if we can execute JavaScript in the browser. | |||
| BubbleableMetadata | class |
Drupal\ |
core/ |
Value object used for bubbleable rendering metadata. | 3 | 64 | |
| BubbleableMetadataTest | class |
Drupal\ |
core/ |
@coversDefaultClass \Drupal\Core\Render\BubbleableMetadata @group Render | |||
| BubblingTest | class |
Drupal\ |
core/ |
||||
| BuilderInterface | interface |
Drupal\ |
composer/ |
Produce the output for a metapackage. | 1 | 1 |