class FullyQualified
Hierarchy
- class \PhpParser\NodeAbstract implements \PhpParser\Node, \PhpParser\JsonSerializable
- class \PhpParser\Node\Name extends \PhpParser\NodeAbstract
- class \PhpParser\Node\Name\FullyQualified extends \PhpParser\Node\Name
- class \PhpParser\Node\Name extends \PhpParser\NodeAbstract
Expanded class hierarchy of FullyQualified
6 files declare their use of FullyQualified
- BuilderHelpers.php in vendor/
nikic/ php-parser/ lib/ PhpParser/ BuilderHelpers.php - DrupalServiceDynamicReturnTypeExtension.php in vendor/
mglaman/ phpstan-drupal/ src/ Type/ DrupalServiceDynamicReturnTypeExtension.php - InvalidRegexPatternRule.php in vendor/
composer/ pcre/ src/ PHPStan/ InvalidRegexPatternRule.php - NameContext.php in vendor/
nikic/ php-parser/ lib/ PhpParser/ NameContext.php - NameResolver.php in vendor/
nikic/ php-parser/ lib/ PhpParser/ NodeVisitor/ NameResolver.php
File
-
vendor/
nikic/ php-parser/ lib/ PhpParser/ Node/ Name/ FullyQualified.php, line 5
Namespace
PhpParser\Node\NameView source
class FullyQualified extends \PhpParser\Node\Name {
/**
* Checks whether the name is unqualified. (E.g. Name)
*
* @return bool Whether the name is unqualified
*/
public function isUnqualified() : bool {
return false;
}
/**
* Checks whether the name is qualified. (E.g. Name\Name)
*
* @return bool Whether the name is qualified
*/
public function isQualified() : bool {
return false;
}
/**
* Checks whether the name is fully qualified. (E.g. \Name)
*
* @return bool Whether the name is fully qualified
*/
public function isFullyQualified() : bool {
return true;
}
/**
* Checks whether the name is explicitly relative to the current namespace. (E.g. namespace\Name)
*
* @return bool Whether the name is relative
*/
public function isRelative() : bool {
return false;
}
public function toCodeString() : string {
return '\\' . $this->toString();
}
public function getType() : string {
return 'Name_FullyQualified';
}
}
Members
Title Sort descending | Modifiers | Object type | Summary | Overriden Title |
---|---|---|---|---|
FullyQualified::getType | public | function | Gets the type of the node. | Overrides Name::getType |
FullyQualified::isFullyQualified | public | function | Checks whether the name is fully qualified. (E.g. \Name) | Overrides Name::isFullyQualified |
FullyQualified::isQualified | public | function | Checks whether the name is qualified. (E.g. Name\Name) | Overrides Name::isQualified |
FullyQualified::isRelative | public | function | Checks whether the name is explicitly relative to the current namespace. (E.g. namespace\Name) | Overrides Name::isRelative |
FullyQualified::isUnqualified | public | function | Checks whether the name is unqualified. (E.g. Name) | Overrides Name::isUnqualified |
FullyQualified::toCodeString | public | function | Returns a string representation of the name as it would occur in code (e.g., including leading backslash for fully qualified names. |
Overrides Name::toCodeString |
Name::$name | public | property | @psalm-var non-empty-string | |
Name::$specialClassNames | private static | property | @var array<string, bool> | |
Name::concat | public static | function | Concatenate two names, yielding a new Name instance. | |
Name::getFirst | public | function | Gets the first part of the name, i.e. everything before the first namespace separator. | |
Name::getLast | public | function | Gets the last part of the name, i.e. everything after the last namespace separator. | |
Name::getParts | public | function | Get parts of name (split by the namespace separator). | |
Name::getSubNodeNames | public | function | Gets the names of the sub nodes. | Overrides Node::getSubNodeNames |
Name::isSpecialClassName | public | function | Checks whether the identifier is a special class name (self, parent or static). | |
Name::prepareName | private static | function | Prepares a (string, array or Name node) name for use in name changing methods by converting it to a string. |
|
Name::slice | public | function | Gets a slice of a name (similar to array_slice). | |
Name::toLowerString | public | function | Returns lowercased string representation of the name, without taking the name type into account (e.g., no leading backslash for fully qualified names). |
|
Name::toString | public | function | Returns a string representation of the name itself, without taking the name type into account (e.g., not including a leading backslash for fully qualified names). |
|
Name::__construct | final public | function | Constructs a name node. | Overrides NodeAbstract::__construct |
Name::__toString | public | function | Returns a string representation of the name by imploding the namespace parts with the namespace separator. |
|
NodeAbstract::$attributes | protected | property | @var array<string, mixed> Attributes | |
NodeAbstract::getAttribute | public | function | Returns the value of an attribute. | Overrides Node::getAttribute |
NodeAbstract::getAttributes | public | function | Returns all the attributes of this node. | Overrides Node::getAttributes |
NodeAbstract::getComments | public | function | Gets all comments directly preceding this node. | Overrides Node::getComments |
NodeAbstract::getDocComment | public | function | Gets the doc comment of the node. | Overrides Node::getDocComment |
NodeAbstract::getEndFilePos | public | function | Gets the file offset of the last character that is part of this node. | Overrides Node::getEndFilePos |
NodeAbstract::getEndLine | public | function | Gets the line the node ended in. | Overrides Node::getEndLine |
NodeAbstract::getEndTokenPos | public | function | Gets the token offset of the last token that is part of this node. | Overrides Node::getEndTokenPos |
NodeAbstract::getLine | public | function | Gets line the node started in (alias of getStartLine). | Overrides Node::getLine |
NodeAbstract::getStartFilePos | public | function | Gets the file offset of the first character that is part of this node. | Overrides Node::getStartFilePos |
NodeAbstract::getStartLine | public | function | Gets line the node started in. | Overrides Node::getStartLine |
NodeAbstract::getStartTokenPos | public | function | Gets the token offset of the first token that is part of this node. | Overrides Node::getStartTokenPos |
NodeAbstract::hasAttribute | public | function | Returns whether an attribute exists. | Overrides Node::hasAttribute |
NodeAbstract::jsonSerialize | public | function | ||
NodeAbstract::setAttribute | public | function | Sets an attribute on a node. | Overrides Node::setAttribute |
NodeAbstract::setAttributes | public | function | Replaces all the attributes of this node. | Overrides Node::setAttributes |
NodeAbstract::setDocComment | public | function | Sets the doc comment of the node. | Overrides Node::setDocComment |