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 |
|---|---|---|---|---|---|---|---|---|
| EntityReferenceFieldItemList | class | Drupal\Core\Field | core/ |
Defines an item list class for entity reference fields. | 2 | 6 | ||
| EntityReferenceFieldItemListInterface | interface | Drupal\Core\Field | core/ |
Interface for entity reference lists of field items. | 1 | 8 | ||
| EntityReferenceFieldItemNormalizer | class | Drupal\serialization\Normalizer | core/ |
Adds the file URI to embedded file entities. | 1 | 2 | ||
| EntityReferenceFieldItemNormalizerTest | class | Drupal\Tests\serialization\Unit\Normalizer | core/ |
Tests Drupal\serialization\Normalizer\EntityReferenceFieldItemNormalizer. | ||||
| EntityReferenceFieldItemNormalizerTrait | trait | Drupal\serialization\Normalizer | core/ |
Converts empty reference values for entity reference items. | ||||
| EntityReferenceFieldNormalizer | class | Drupal\jsonapi\Normalizer | core/ |
Normalizer class specific for entity reference field objects. | ||||
| EntityReferenceFieldTest | class | Drupal\KernelTests\Core\Entity | core/ |
Tests for the entity reference field. | ||||
| EntityReferenceFieldTranslatedReferenceViewTest | class | Drupal\Tests\field\Functional\EntityReference | core/ |
Tests the translation of entity reference field display on nodes. | ||||
| EntityReferenceFileUploadTest | class | Drupal\Tests\field\Functional\EntityReference | core/ |
Tests an autocomplete widget with file upload. | ||||
| EntityReferenceFormatterBase | abstract class | Drupal\Core\Field\Plugin\Field\FieldFormatter | core/ |
Parent plugin for entity reference formatters. | 7 | 4 | ||
| EntityReferenceFormatterTest | class | Drupal\Tests\field\Kernel\EntityReference | core/ |
Tests the formatters functionality. | ||||
| EntityReferenceIdFormatter | class | Drupal\Core\Field\Plugin\Field\FieldFormatter | core/ |
Plugin implementation of the 'entity reference ID' formatter. | ||||
| EntityReferenceIntegrationTest | class | Drupal\Tests\field\Functional\EntityReference | core/ |
Tests various Entity reference UI components. | ||||
| EntityReferenceItem | class | Drupal\Core\Field\Plugin\Field\FieldType | core/ |
Defines the 'entity_reference' entity field type. | 3 | 19 | ||
| EntityReferenceItemBase | abstract class | Drupal\Core\Field\Plugin\Field\FieldType | core/ |
Base class for field items referencing other entities. | 1 | |||
| EntityReferenceItemInterface | interface | Drupal\Core\Field\Plugin\Field\FieldType | core/ |
Interface definition for field items referencing other entities. | 1 | 2 | ||
| EntityReferenceItemSubclass | class | Drupal\media_library_test\Plugin\Field\FieldType | core/ |
Plugin implementation of the 'entity_reference_subclass' field type. | ||||
| EntityReferenceItemTest | class | Drupal\Tests\field\Kernel\EntityReference | core/ |
Tests the new entity API for the entity reference field type. | ||||
| EntityReferenceLabelFormatter | class | Drupal\Core\Field\Plugin\Field\FieldFormatter | core/ |
Plugin implementation of the 'entity reference label' formatter. | ||||
| EntityReferenceRelationshipTest | class | Drupal\Tests\field\Kernel\EntityReference\Views | core/ |
Tests entity reference relationship data. | ||||
| EntityReferenceSelection | class | Drupal\Core\Entity\Attribute | core/ |
Defines an EntityReferenceSelection attribute for plugin discovery. | 14 | |||
| EntityReferenceSelection | class | Drupal\Core\Entity\Annotation | core/ |
Defines an EntityReferenceSelection plugin annotation object. | ||||
| EntityReferenceSelectionAccessTest | class | Drupal\Tests\system\Kernel\Entity\EntityReferenceSelection | core/ |
Tests for the base handlers provided by Entity Reference. | ||||
| EntityReferenceSelectionReferenceableTest | class | Drupal\Tests\system\Kernel\Entity | core/ |
Tests entity reference selection plugins. | ||||
| EntityReferenceSelectionSortTest | class | Drupal\KernelTests\Core\Entity\EntityReferenceSelection | core/ |
Tests sorting referenced items. | ||||
| EntityReferenceSettingsTest | class | Drupal\Tests\field\Kernel\EntityReference | core/ |
Tests entity reference field settings. | ||||
| EntityReferenceSupportedNewEntitiesConstraint | class | Drupal\workspaces\Plugin\Validation\Constraint | core/ |
The entity reference supported new entities constraint. | ||||
| EntityReferenceSupportedNewEntitiesConstraintValidator | class | Drupal\workspaces\Plugin\Validation\Constraint | core/ |
Checks if new entities created for entity reference fields are supported. | 1 | |||
| EntityReferenceSupportedNewEntitiesConstraintValidatorTest | class | Drupal\Tests\workspaces\Kernel | core/ |
Tests Drupal\workspaces\Plugin\Validation\Constraint\EntityReferenceSupportedNewEntitiesConstraintValidator. | ||||
| EntityReferenceTaxonomyTermRssFormatter | class | Drupal\taxonomy\Plugin\Field\FieldFormatter | core/ |
Plugin implementation of the 'entity reference taxonomy term RSS' formatter. | ||||
| EntityReferenceTestHooks | class | Drupal\entity_reference_test\Hook | core/ |
Hook implementations for entity_reference_test. | ||||
| EntityReferenceTranslationDeriver | class | Drupal\migrate_drupal\Plugin\migrate | core/ |
Deriver for entity reference field translations. | 2 | |||
| EntityReferenceUuidItem | class | Drupal\jsonapi_test_field_type\Plugin\Field\FieldType | core/ |
Defines the 'entity_reference_uuid' entity field type. | ||||
| EntityReferenceWidgetTest | class | Drupal\Tests\media_library\FunctionalJavascript | core/ |
Tests the Media library entity reference widget. | 1 | 1 | ||
| EntityReferenceXSSTest | class | Drupal\Tests\field\Functional\EntityReference | core/ |
Tests possible XSS security issues in entity references. | ||||
| EntityRepository | class | Drupal\Core\Entity | core/ |
Provides several mechanisms for retrieving entities. | 2 | 2 | ||
| EntityRepositoryInterface | interface | Drupal\Core\Entity | core/ |
Provides an interface for an entity repository. | 2 | 80 | ||
| EntityRepositoryTest | class | Drupal\KernelTests\Core\Entity | core/ |
Tests the entity repository. | ||||
| EntityRepositoryTest | class | Drupal\Tests\Core\Entity | core/ |
Tests Drupal\Core\Entity\EntityRepository. | ||||
| EntityResolverInterface | interface | Drupal\serialization\EntityResolver | core/ |
Interface for entity resolvers. | 3 | |||
| EntityResolverManager | class | Drupal\Core\Entity | core/ |
Sets the entity route parameter converter options automatically. | 2 | 2 | ||
| EntityResolverManagerTest | class | Drupal\Tests\Core\Entity | core/ |
Tests Drupal\Core\Entity\EntityResolverManager. | ||||
| EntityResource | class | Drupal\rest\Plugin\rest\resource | core/ |
Represents entities as resources. | 1 | 1 | ||
| EntityResource | class | Drupal\jsonapi\Controller | core/ |
Process all entity requests. | 1 | 2 | ||
| EntityResourceAccessTrait | trait | Drupal\rest\Plugin\rest\resource | core/ |
@internal @todo Consider making public in https://www.drupal.org/node/2300677 | 1 | |||
| EntityResourcePostRouteSubscriber | class | Drupal\rest\EventSubscriber | core/ |
Generates a 'create' route for an entity type if it has a REST POST route. | 2 | |||
| EntityResourceRestTestCoverageTest | class | Drupal\Tests\rest\Kernel\EntityResource | core/ |
Checks that all core content/config entity types have REST test coverage. | ||||
| EntityResourceTest | class | Drupal\Tests\jsonapi\Kernel\Controller | core/ |
Tests Drupal\jsonapi\Controller\EntityResource. | ||||
| EntityResourceTestBase | abstract class | Drupal\Tests\rest\Functional\EntityResource | core/ |
Defines a base class for testing all entity resources. | 13 | 12 | ||
| EntityResourceValidationTrait | trait | Drupal\rest\Plugin\rest\resource | core/ |
@internal @todo Consider making public in https://www.drupal.org/node/2300677 | 3 |
Pagination
- Previous page
- Page 65
- Next page
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.