Classes, traits, and interfaces - 9.5.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 1523
Name | Deprecated | Object type | Namespace | File name | Summary | Direct uses | Use statements | Strings |
---|---|---|---|---|---|---|---|---|
ControllerResolverInterface | interface | Drupal\Core\Controller | core/ |
Extends the ControllerResolverInterface from symfony. | 1 | 7 | ||
ControllerResolverTest | class | Drupal\Tests\Core\Controller | core/ |
@coversDefaultClass \Drupal\Core\Controller\ControllerResolver @group Controller | ||||
Convert | class | Drupal\system\Plugin\ImageToolkit\Operation\gd | core/ |
Defines GD2 convert operation. | ||||
ConvertImageEffect | class | Drupal\image\Plugin\ImageEffect | core/ |
Converts an image resource. | ||||
ConvertTest | class | Drupal\Tests\image\Functional\ImageEffect | core/ |
Tests for the Convert image effect. | ||||
ConvertTokens | class | Drupal\user\Plugin\migrate\process | core/ |
Plugin to replace !tokens with [tokens]. | 1 | |||
ConvertTokensTest | class | Drupal\Tests\user\Unit\Plugin\migrate\process | core/ |
Tests the ConvertTokens plugin. | ||||
Cookie | class | Drupal\user\Authentication\Provider | core/ |
Cookie based authentication provider. | 1 | 2 | ||
CookieCacheContextTest | class | Drupal\Tests\Core\Cache\Context | core/ |
@coversDefaultClass \Drupal\Core\Cache\Context\CookiesCacheContext @group Cache | ||||
CookieResourceTestTrait | trait | Drupal\Tests\rest\Functional | core/ |
Trait for ResourceTestBase subclasses testing $auth=cookie. | 156 | |||
CookiesCacheContext | class | Drupal\Core\Cache\Context | core/ |
Defines the CookiesCacheContext service, for "per cookie" caching. | 1 | 2 | ||
CopyTest | class | Drupal\Tests\file\Kernel | core/ |
Tests the file copy function. | ||||
Core | class | Drupal\ckeditor5\Plugin\CKEditor4To5Upgrade | core/ |
Provides the CKEditor 4 to 5 upgrade for Drupal core's CKEditor plugins. | ||||
CoreServiceProvider | class | Drupal\Core | core/ |
ServiceProvider class for mandatory core services. | ||||
CoreThemesAutoloadedForTests | class | Drupal\Tests\Core\Theme | core/ |
Confirms that core/themes is autoloaded for tests. | ||||
Corn | class | Drupal\Tests\Component\Plugin\Fixtures\vegetable | core/ |
Plugin annotation @Plugin( id = "corn", label = "Corn", color = "yellow" ) | 1 | |||
CorsCompilerPass | class | Drupal\Core\DependencyInjection\Compiler | core/ |
Provides a compiler pass which disables the CORS middleware in case disabled. | 1 | |||
CorsIntegrationTest | class | Drupal\FunctionalTests\HttpKernel | core/ |
Tests CORS provided by Drupal. | ||||
CountableResourceType | class | Drupal\jsonapi_test_collection_count\ResourceType | core/ |
Subclass with overridden ::includeCount() for testing purposes. | ||||
CountableResourceTypeRepository | class | Drupal\jsonapi_test_collection_count\ResourceType | core/ |
Provides a repository of JSON:API configurable resource types. | 2 | |||
CountConstraint | class | Drupal\Core\Validation\Plugin\Validation\Constraint | core/ |
Count constraint. | ||||
Counter | class | Drupal\views\Plugin\views\field | core/ |
Field handler to show a counter of the current row. | 1 | |||
CounterTest | class | Drupal\Tests\views\Unit\Plugin\field | core/ |
@coversDefaultClass \Drupal\views\Plugin\views\field\Counter @group views | ||||
CountryManager | class | Drupal\Core\Locale | core/ |
Provides list of countries. | 2 | |||
CountryManagerInterface | interface | Drupal\Core\Locale | core/ |
Defines a common interface for country managers. | 1 | 2 | ||
CreatedItem | class | Drupal\Core\Field\Plugin\Field\FieldType | core/ |
Defines the 'created' entity field type. | 1 | 3 | ||
CreateMigrationsTrait | trait | Drupal\Tests\migrate_drupal\Traits | core/ |
1 | ||||
CreateNew | class | Drupal\system\Plugin\ImageToolkit\Operation\gd | core/ |
Defines GD2 create_new image operation. | ||||
CreateSampleEntityTest | class | Drupal\KernelTests\Core\Entity | core/ |
Tests the ContentEntityStorageBase::createWithSampleValues method. | ||||
CreateTestContentEntitiesTrait | trait | Drupal\Tests\migrate_drupal\Traits | core/ |
Provides helper methods for creating test content. | 8 | |||
CredentialForm | class | Drupal\migrate_drupal_ui\Form | core/ |
Migrate Upgrade database credential form. | 1 | |||
CredentialFormTest | class | Drupal\Tests\migrate_drupal_ui\Functional | core/ |
Test the credential form for both Drupal 6 and Drupal 7 sources. | ||||
Cron | class | Drupal\Core\ProxyClass | core/ |
Provides a proxy class for \Drupal\Core\Cron. | ||||
Cron | class | Drupal\Core | core/ |
The Drupal core Cron service. | 1 | 2 | ||
CronAccessCheck | class | Drupal\system\Access | core/ |
Access check for cron routes. | 2 | |||
CronController | class | Drupal\system | core/ |
Controller for Cron handling. | ||||
CronForm | class | Drupal\system\Form | core/ |
Configure cron settings for this site. | 1 | |||
CronInterface | interface | Drupal\Core | core/ |
An interface for running cron tasks. | 2 | 3 | ||
CronQueueTest | class | Drupal\Tests\system\Kernel\System | core/ |
Tests the Cron Queue runner. | ||||
CronQueueTestBrokenQueue | class | Drupal\cron_queue_test\Plugin\QueueWorker | core/ |
Plugin annotation @QueueWorker( id = "cron_queue_test_broken_queue", title = @Translation("Broken queue test"), cron = {"time" = 60} ) | ||||
CronQueueTestDatabaseDelayException | class | Drupal\cron_queue_test\Plugin\QueueWorker | core/ |
A queue worker for testing cron exception handling. | 1 | |||
CronQueueTestException | class | Drupal\cron_queue_test\Plugin\QueueWorker | core/ |
Plugin annotation @QueueWorker( id = "cron_queue_test_exception", title = @Translation("Exception test"), cron = {"time" = 1} ) | ||||
CronQueueTestLeaseTime | class | Drupal\cron_queue_test\Plugin\QueueWorker | core/ |
Plugin annotation @QueueWorker( id = "cron_queue_test_lease_time", title = @Translation("Lease time test"), cron = {"time" = 100} ) | ||||
CronQueueTestMemoryDelayException | class | Drupal\cron_queue_test\Plugin\QueueWorker | core/ |
A queue worker for testing cron exception handling. | ||||
CronQueueTestRequeueException | class | Drupal\cron_queue_test\Plugin\QueueWorker | core/ |
Plugin annotation @QueueWorker( id = "cron_queue_test_requeue_exception", title = @Translation("RequeueException test"), cron = {"time" = 60} ) | ||||
CronRunTest | class | Drupal\Tests\system\Functional\System | core/ |
Tests cron runs. | ||||
CronRunTrait | trait | Drupal\Tests\Traits\Core | core/ |
Adds ability to run cron from tests. | 16 | |||
CronTest | class | Drupal\Tests\Core | core/ |
Tests the Cron class. | ||||
Crop | class | Drupal\system\Plugin\ImageToolkit\Operation\gd | core/ |
Defines GD2 Crop operation. | ||||
CropImageEffect | class | Drupal\image\Plugin\ImageEffect | core/ |
Crops an image resource. | 1 |
Pagination
- Previous page
- Page 37
- Next page
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.