function ConstantHelper::getFullyQualifiedName
File
-
vendor/
slevomat/ coding-standard/ SlevomatCodingStandard/ Helpers/ ConstantHelper.php, line 28
Class
- ConstantHelper
- @internal
Namespace
SlevomatCodingStandard\HelpersCode
public static function getFullyQualifiedName(File $phpcsFile, int $constantPointer) : string {
$name = self::getName($phpcsFile, $constantPointer);
$namespace = NamespaceHelper::findCurrentNamespaceName($phpcsFile, $constantPointer);
return $namespace !== null ? sprintf('%s%s%s%s', NamespaceHelper::NAMESPACE_SEPARATOR, $namespace, NamespaceHelper::NAMESPACE_SEPARATOR, $name) : $name;
}