Classes, traits, and interfaces - Drupal 11.1.x - Drupal Core
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
File
-
core/
core.api.php, line 1518
Name | Deprecated | Object type | Namespace | File name | Summary | Direct uses | Use statements | Strings |
---|---|---|---|---|---|---|---|---|
FulfilledPromise | final class | Http\Promise | vendor/ |
A promise already fulfilled. | ||||
FulfilledPromise | class | GuzzleHttp\Promise | vendor/ |
A promise that has been fulfilled. | 2 | |||
Full | class | PHP_CodeSniffer\Reports | vendor/ |
|||||
Full | class | Drupal\views\Plugin\views\pager | core/ |
The plugin to handle full pager. | 1 | |||
FullDate | class | Drupal\datetime\Plugin\views\argument | core/ |
Argument handler for a full date (CCYYMMDD). | ||||
FullDate | class | Drupal\views\Plugin\views\argument | core/ |
Argument handler for a full date (CCYYMMDD) | ||||
FullyQualified | class | PhpParser\Node\Name | vendor/ |
6 | ||||
FullyQualifiedClassNameInAnnotationSniff | class | SlevomatCodingStandard\Sniffs\Namespaces | vendor/ |
|||||
FullyQualifiedExceptionsSniff | class | SlevomatCodingStandard\Sniffs\Namespaces | vendor/ |
|||||
FullyQualifiedGlobalConstantsSniff | class | SlevomatCodingStandard\Sniffs\Namespaces | vendor/ |
|||||
FullyQualifiedGlobalFunctionsSniff | class | SlevomatCodingStandard\Sniffs\Namespaces | vendor/ |
|||||
FullyQualifiedNamespaceSniff | class | Drupal\Sniffs\Classes | vendor/ |
Checks that class references do not use FQN but use statements. | ||||
FullyValidatableConstraint | final class | Drupal\Core\Validation\Plugin\Validation\Constraint | core/ |
Constraint for fully validatable config schema type. | 3 | |||
FullyValidatableConstraintValidator | final class | Drupal\Core\Validation\Plugin\Validation\Constraint | core/ |
FullyValidatable constraint. | ||||
FuncCall | class | PhpParser\Node\Expr | vendor/ |
4 | ||||
FunctionAliasSniff | class | Drupal\Sniffs\Semantics | vendor/ |
Checks that no PHP function name aliases are used. | ||||
FunctionalTestSetupTrait | trait | Drupal\Core\Test | core/ |
Defines a trait for shared functional test setup functionality. | ||||
FunctionCall | abstract class | Drupal\Sniffs\Semantics | vendor/ |
Helper class to sniff for specific function calls. | 22 | 15 | ||
FunctionCallArgumentSpacingSniff | class | PHP_CodeSniffer\Standards\Generic\Sniffs\Functions | vendor/ |
1 | ||||
FunctionCallSignatureSniff | class | PHP_CodeSniffer\Standards\PEAR\Sniffs\Functions | vendor/ |
1 | 1 | |||
FunctionCallSignatureSniff | class | PHP_CodeSniffer\Standards\PSR2\Sniffs\Methods | vendor/ |
|||||
FunctionClosingBraceSniff | class | PHP_CodeSniffer\Standards\PSR2\Sniffs\Methods | vendor/ |
|||||
FunctionClosingBraceSpaceSniff | class | PHP_CodeSniffer\Standards\Squiz\Sniffs\WhiteSpace | vendor/ |
|||||
FunctionCommentSniff | class | PHP_CodeSniffer\Standards\PEAR\Sniffs\Commenting | vendor/ |
1 | 1 | |||
FunctionCommentSniff | class | Drupal\Sniffs\Commenting | vendor/ |
Parses and verifies the doc comments for functions. Largely copied from PHP_CodeSniffer\Standards\Squiz\Sniffs\Commenting\FunctionCommentSniff. | ||||
FunctionCommentSniff | class | PHP_CodeSniffer\Standards\MySource\Sniffs\Commenting | vendor/ |
|||||
FunctionCommentSniff | class | PHP_CodeSniffer\Standards\Squiz\Sniffs\Commenting | vendor/ |
1 | 1 | |||
FunctionCommentThrowTagSniff | class | PHP_CodeSniffer\Standards\Squiz\Sniffs\Commenting | vendor/ |
|||||
FunctionDeclaration | class | Peast\Syntax\Node | vendor/ |
A node that represents a function declaration For example: function test () {} | ||||
FunctionDeclarationArgumentSpacingSniff | class | PHP_CodeSniffer\Standards\Squiz\Sniffs\Functions | vendor/ |
|||||
FunctionDeclarationSniff | class | PHP_CodeSniffer\Standards\PEAR\Sniffs\Functions | vendor/ |
1 | 2 | |||
FunctionDeclarationSniff | in Coder 8.x, will be removed in Coder 9.x. MultiLineFunctionDeclarationSniff is used instead. |
class | Drupal\Sniffs\Functions | vendor/ |
Ensure that there is only one space after the function keyword and no space before the opening parenthesis. | |||
FunctionDeclarationSniff | class | PHP_CodeSniffer\Standards\Squiz\Sniffs\Functions | vendor/ |
|||||
FunctionDefinition | abstract class | Drupal\Sniffs\Semantics | vendor/ |
Helper class to sniff for function definitions. | 9 | 5 | ||
FunctionDuplicateArgumentSniff | class | PHP_CodeSniffer\Standards\Squiz\Sniffs\Functions | vendor/ |
|||||
FunctionExpression | class | Twig\Node\Expression | vendor/ |
2 | 10 | |||
FunctionExpression | class | Peast\Syntax\Node | vendor/ |
A node that represents a function expression For example: var test = function () {} | ||||
FunctionExtension | class | Symfony\Component\CssSelector\XPath\Extension | vendor/ |
XPath expression translator function extension. | ||||
FunctionHelper | class | SlevomatCodingStandard\Helpers | vendor/ |
@internal | 23 | |||
FunctionLengthSniff | class | SlevomatCodingStandard\Sniffs\Functions | vendor/ |
|||||
FunctionLike | abstract class | PhpParser\Builder | vendor/ |
2 | ||||
FunctionLike | interface | PhpParser\Node | vendor/ |
5 | 4 | |||
FunctionNode | class | Symfony\Component\CssSelector\Node | vendor/ |
Represents a "<selector>:<name>(<arguments>)" node. | 3 | |||
FunctionOpeningBraceSpaceSniff | class | PHP_CodeSniffer\Standards\Squiz\Sniffs\WhiteSpace | vendor/ |
|||||
FunctionSpacingSniff | class | PHP_CodeSniffer\Standards\Squiz\Sniffs\WhiteSpace | vendor/ |
|||||
FunctionTriggerErrorSniff | class | Drupal\Sniffs\Semantics | vendor/ |
Checks that the trigger_error deprecation text message adheres to standards. | ||||
FunctionTSniff | class | Drupal\Sniffs\Semantics | vendor/ |
Check the usage of the t() function to not escape translatable strings with back slashes. Also checks that the first argument does not use string concatenation. | ||||
FunctionUnit | final class | SebastianBergmann\CodeUnit | vendor/ |
@psalm-immutable | ||||
FunctionWatchdogSniff | class | Drupal\Sniffs\Semantics | vendor/ |
Checks that the second argument to watchdog() is not enclosed with t(). | ||||
Function_ | class | PhpParser\Builder | vendor/ |