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 |
---|---|---|---|---|---|---|---|---|
CsrfTokenController | class | Drupal\system\Controller | core/ |
Returns responses for CSRF token routes. | ||||
CsrfTokenGenerator | class | Drupal\Core\Access | core/ |
Generates and validates CSRF tokens. | 13 | 2 | ||
CsrfTokenGeneratorTest | class | Drupal\Tests\Core\Access | core/ |
Tests the CsrfTokenGenerator class. | ||||
CsrfTokenRaceTest | class | Drupal\FunctionalJavascriptTests\Core | core/ |
Test race condition for CSRF tokens for simultaneous requests. | ||||
CssAssetController | class | Drupal\system\Controller | core/ |
Defines a controller to serve CSS aggregates. | ||||
CssCollectionGrouper | class | Drupal\Core\Asset | core/ |
Groups CSS assets. | 1 | 2 | ||
CssCollectionGrouperUnitTest | class | Drupal\Tests\Core\Asset | core/ |
Tests the CSS asset collection grouper. | ||||
CssCollectionOptimizer | in drupal:10.1.0 and is removed from drupal:11.0.0. Instead, use \Drupal\Core\Asset\CssCollectionOptimizerLazy. |
class | Drupal\Core\Asset | core/ |
Optimizes CSS assets. | 1 | ||
CssCollectionOptimizerLazy | class | Drupal\Core\Asset | core/ |
Optimizes CSS assets. | 1 | 2 | ||
CssCollectionOptimizerLazyUnitTest | class | Drupal\Tests\Core\Asset | core/ |
Tests the CSS asset optimizer. | ||||
CssCollectionOptimizerUnitTest | class | Drupal\Tests\Core\Asset | core/ |
Tests the CSS asset optimizer. | ||||
CssCollectionRenderer | class | Drupal\Core\Asset | core/ |
Renders CSS assets. | 1 | 2 | ||
CssCollectionRendererUnitTest | class | Drupal\Tests\Core\Asset | core/ |
Tests the CSS asset collection renderer. | ||||
CssCommand | class | Drupal\Core\Ajax | core/ |
An AJAX command for calling the jQuery css() method. | 2 | |||
CssOptimizer | class | Drupal\Core\Asset | core/ |
Optimizes a CSS asset. | 1 | 2 | ||
CssOptimizerUnitTest | class | Drupal\Tests\Core\Asset | core/ |
Tests the CSS asset optimizer. | ||||
Current | class | Drupal\user\Plugin\views\filter | core/ |
Filter handler for the current user. | ||||
CurrentLanguageContext | class | Drupal\Core\Language\ContextProvider | core/ |
Sets the current language as a context. | 2 | |||
CurrentPathStack | class | Drupal\Core\Path | core/ |
Represents the current path for the current request. | 18 | 2 | ||
CurrentRouteMatch | class | Drupal\Core\Routing | core/ |
Default object for current_route_match service. | 3 | 2 | ||
CurrentRouteMatchTest | class | Drupal\Tests\Core\Routing | core/ |
@coversDefaultClass \Drupal\Core\Routing\CurrentRouteMatch @group Routing | ||||
CurrentThemeCondition | class | Drupal\system\Plugin\Condition | core/ |
Provides a 'Current Theme' condition. | ||||
CurrentThemeConditionTest | class | Drupal\KernelTests\Core\Plugin\Condition | core/ |
Tests the CurrentThemeCondition plugin. | ||||
CurrentUser | class | Drupal\user\Plugin\views\argument_default | core/ |
Default argument plugin to extract the current user. | ||||
CurrentUserContext | class | Drupal\user\ContextProvider | core/ |
Sets the current user as a context. | 2 | |||
CurrentUserContextTest | class | Drupal\Tests\user\Kernel\ContextProvider | core/ |
@coversDefaultClass \Drupal\user\ContextProvider\CurrentUserContext | ||||
Custom | class | Drupal\views\Plugin\views\field | core/ |
A handler to provide a field that is completely custom by the administrator. | ||||
CustomAccessCheck | class | Drupal\Core\Access | core/ |
Defines an access checker that allows specifying a custom method for access. | 1 | 2 | ||
CustomAccessCheckTest | class | Drupal\Tests\Core\Access | core/ |
@coversDefaultClass \Drupal\Core\Access\CustomAccessCheck @group Access | ||||
CustomAnnotationClassDiscoveryTest | class | Drupal\KernelTests\Core\Plugin\Discovery | core/ |
Tests that a custom annotation class is used. | ||||
CustomBooleanTest | class | Drupal\Tests\views_ui\Functional | core/ |
Tests the UI and functionality for the Custom boolean field handler options. | ||||
CustomDirectoryAnnotatedClassDiscoveryTest | class | Drupal\KernelTests\Core\Plugin\Discovery | core/ |
Tests discovery of annotated plugins in a custom directory. | ||||
CustomDirectoryExample1 | class | Drupal\plugin_test | core/ |
Provides a test plugin within a custom directory. | ||||
CustomDirectoryExample2 | class | Drupal\plugin_test | core/ |
Provides a test plugin within a custom directory. | ||||
CustomFileCache | class | Drupal\Tests\Component\FileCache | core/ |
|||||
CustomPageExceptionHtmlSubscriber | class | Drupal\Core\EventSubscriber | core/ |
Exception subscriber for handling core custom HTML error pages. | 1 | 2 | ||
CustomPageExceptionHtmlSubscriberTest | class | Drupal\Tests\Core\EventSubscriber | core/ |
@coversDefaultClass \Drupal\Core\EventSubscriber\CustomPageExceptionHtmlSubscriber @group EventSubscriber | ||||
CustomPlugin | class | Drupal\Tests\Component\Annotation | core/ |
Custom plugin annotation. | ||||
CustomPlugin | class | com\example\PluginNamespace | core/ |
Custom plugin attribute. | ||||
CustomPlugin | class | com\example\PluginNamespace | core/ |
Custom plugin attribute. | ||||
CustomPlugin2 | class | com\example\PluginNamespace | core/ |
Custom plugin attribute. | ||||
CustomPlugin2 | class | Drupal\Tests\Component\Annotation | core/ |
Custom plugin annotation. | ||||
CustomPlugin2 | class | com\example\PluginNamespace | core/ |
Custom plugin attribute. | ||||
CustomStrings | class | Drupal\Core\StringTranslation\Translator | core/ |
String translator using overrides from variables. | 2 | |||
CustomThemeNegotiator | class | Drupal\theme_test\Theme | core/ |
Just forces the 'test_theme' theme. | 2 | |||
D6FileField | class | Drupal\migrate_field_plugin_manager_test\Plugin\migrate\field | core/ |
MigrateField Plugin for Drupal 6 file fields. | ||||
D6NoCoreVersionSpecified | class | Drupal\migrate_field_plugin_manager_test\Plugin\migrate\field | core/ |
|||||
D6NodeDeriver | class | Drupal\node\Plugin\migrate | core/ |
Deriver for Drupal 6 node and node revision migrations based on node types. | 4 | |||
D6NodeTranslation | class | Drupal\node\Plugin\migrate | core/ |
Migration plugin for the Drupal 6 node translations. | 2 | |||
D6TermNodeDeriver | class | Drupal\taxonomy\Plugin\migrate | core/ |
Deriver for Drupal 6 term node migrations based on vocabularies. | 3 |
Pagination
- Previous page
- Page 41
- Next page
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.