You are here

Classes, traits, and interfaces in Drupal 8

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

Namesort descending Type Namespace Location Description Direct uses Use statements Strings
YamlSymfony class Drupal\Component\Serialization core/lib/Drupal/Component/Serialization/YamlSymfony.php Default serialization for YAML using the Symfony component. 2
YamlSymfonyTest class Drupal\Tests\Component\Serialization core/tests/Drupal/Tests/Component/Serialization/YamlSymfonyTest.php Tests the YamlSymfony serialization implementation.
YamlTest class Drupal\Tests\Component\Serialization core/tests/Drupal/Tests/Component/Serialization/YamlTest.php @coversDefaultClass \Drupal\Component\Serialization\Yaml @group Serialization
YamlTest class Drupal\Tests\Core\Serialization core/tests/Drupal/Tests/Core/Serialization/YamlTest.php @coversDefaultClass \Drupal\Core\Serialization\Yaml @group Serialization
YamlTestBase abstract class Drupal\Tests\Component\Serialization core/tests/Drupal/Tests/Component/Serialization/YamlTestBase.php Provides standard data to validate different YAML implementations. 2
YearDate class Drupal\views\Plugin\views\argument core/modules/views/src/Plugin/views/argument/YearDate.php Argument handler for a year (CCYY)
YearDate class Drupal\datetime\Plugin\views\argument core/modules/datetime/src/Plugin/views/argument/YearDate.php Argument handler for a year.
YearMonthDate class Drupal\datetime\Plugin\views\argument core/modules/datetime/src/Plugin/views/argument/YearMonthDate.php Argument handler for a year plus month (CCYYMM).
YearMonthDate class Drupal\views\Plugin\views\argument core/modules/views/src/Plugin/views/argument/YearMonthDate.php Argument handler for a year plus month (CCYYMM)
ZfExtensionManagerSfContainer class Drupal\Component\Bridge core/lib/Drupal/Component/Bridge/ZfExtensionManagerSfContainer.php Defines a bridge between the Laminas service manager to Symfony container. 1 3
ZfExtensionManagerSfContainerTest class Drupal\Tests\Component\Bridge core/tests/Drupal/Tests/Component/Bridge/ZfExtensionManagerSfContainerTest.php @coversDefaultClass \Drupal\Component\Bridge\ZfExtensionManagerSfContainer @group Bridge
Zip class Drupal\Core\Archiver core/lib/Drupal/Core/Archiver/Zip.php Defines a archiver implementation for .zip files. 1 1
Zip class Drupal\system\Plugin\Archiver core/modules/system/src/Plugin/Archiver/Zip.php Defines an archiver implementation for .zip files.

Pages

Other projects