Table of Contents
-
$constExprParser
: ConstExprParser|null
-
$quoteAwareConstExprString
: bool
-
$useIndexAttributes
: bool
-
$useLinesAttributes
: bool
-
__construct()
: mixed
-
isHtml()
: bool
-
parse()
: TypeNode
-
parseGeneric()
: GenericTypeNode
-
parseGenericTypeArgument()
: array{: \PHPStan\PhpDocParser\Ast\Type\TypeNode, : \PHPStan\PhpDocParser\Ast\Type\GenericTypeNode::VARIANCE_*}
-
parseTemplateTagValue()
: TemplateTagValueNode
-
parseArrayShape()
: ArrayShapeNode
-
parseArrayShapeItem()
: ArrayShapeItemNode
-
parseArrayShapeKey()
: ConstExprIntegerNode|ConstExprStringNode|IdentifierTypeNode
-
parseAtomic()
: TypeNode
-
parseCallable()
: TypeNode
-
parseCallableParameter()
: CallableTypeParameterNode
-
parseCallableReturnType()
: TypeNode
-
parseCallableTemplateArgument()
: TemplateTagValueNode
-
parseCallableTemplates()
: array<string|int, TemplateTagValueNode>
-
parseConditional()
: TypeNode
-
parseConditionalForParameter()
: TypeNode
-
parseIntersection()
: TypeNode
-
parseNullable()
: TypeNode
-
parseObjectShape()
: ObjectShapeNode
-
parseObjectShapeItem()
: ObjectShapeItemNode
-
parseObjectShapeKey()
: ConstExprStringNode|IdentifierTypeNode
-
parseUnion()
: TypeNode
-
subParse()
: TypeNode
-
subParseIntersection()
: TypeNode
-
subParseUnion()
: TypeNode
-
tryParseArrayOrOffsetAccess()
: TypeNode
-
tryParseCallable()
: TypeNode
$constExprParser
private
ConstExprParser|null
$constExprParser
$quoteAwareConstExprString
private
bool
$quoteAwareConstExprString
$useIndexAttributes
private
bool
$useIndexAttributes
$useLinesAttributes
private
bool
$useLinesAttributes
__construct()
public
__construct([ConstExprParser|null $constExprParser = null ][, bool $quoteAwareConstExprString = false ][, array{lines?: bool, indexes?: bool} $usedAttributes = [] ]) : mixed
Parameters
-
$constExprParser
: ConstExprParser|null
= null
-
-
$quoteAwareConstExprString
: bool
= false
-
-
$usedAttributes
: array{lines?: bool, indexes?: bool}
= []
-
Return values
mixed
—
isHtml()
public
isHtml(TokenIterator $tokens) : bool
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
bool
—
parse()
public
parse(TokenIterator $tokens) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
TypeNode
—
parseGeneric()
public
parseGeneric(TokenIterator $tokens, IdentifierTypeNode $baseType) : GenericTypeNode
Parameters
-
$tokens
: TokenIterator
-
-
$baseType
: IdentifierTypeNode
-
-
phpstan-impure
-
Return values
GenericTypeNode
—
parseGenericTypeArgument()
public
parseGenericTypeArgument(TokenIterator $tokens) : array{: \PHPStan\PhpDocParser\Ast\Type\TypeNode, : \PHPStan\PhpDocParser\Ast\Type\GenericTypeNode::VARIANCE_*}
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
array{: \PHPStan\PhpDocParser\Ast\Type\TypeNode, : \PHPStan\PhpDocParser\Ast\Type\GenericTypeNode::VARIANCE_*}
—
parseTemplateTagValue()
public
parseTemplateTagValue(TokenIterator $tokens[, callable|null $parseDescription = null ]) : TemplateTagValueNode
Parameters
-
$tokens
: TokenIterator
-
-
$parseDescription
: callable|null
= null
-
-
throws
-
ParserException
Return values
TemplateTagValueNode
—
parseArrayShape()
private
parseArrayShape(TokenIterator $tokens, TypeNode $type, \PHPStan\PhpDocParser\Ast\Type\ArrayShapeNode::KIND_* $kind) : ArrayShapeNode
Parameters
-
$tokens
: TokenIterator
-
-
$type
: TypeNode
-
-
$kind
: \PHPStan\PhpDocParser\Ast\Type\ArrayShapeNode::KIND_*
-
-
phpstan-impure
-
Return values
ArrayShapeNode
—
parseArrayShapeItem()
private
parseArrayShapeItem(TokenIterator $tokens) : ArrayShapeItemNode
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
ArrayShapeItemNode
—
parseArrayShapeKey()
private
parseArrayShapeKey(TokenIterator $tokens) : ConstExprIntegerNode|ConstExprStringNode|IdentifierTypeNode
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
ConstExprIntegerNode|ConstExprStringNode|IdentifierTypeNode
—
parseAtomic()
private
parseAtomic(TokenIterator $tokens) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
TypeNode
—
parseCallable()
private
parseCallable(TokenIterator $tokens, IdentifierTypeNode $identifier, bool $hasTemplate) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
$identifier
: IdentifierTypeNode
-
-
$hasTemplate
: bool
-
-
phpstan-impure
-
Return values
TypeNode
—
parseCallableParameter()
private
parseCallableParameter(TokenIterator $tokens) : CallableTypeParameterNode
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
CallableTypeParameterNode
—
parseCallableReturnType()
private
parseCallableReturnType(TokenIterator $tokens) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
TypeNode
—
parseCallableTemplateArgument()
private
parseCallableTemplateArgument(TokenIterator $tokens) : TemplateTagValueNode
Parameters
-
$tokens
: TokenIterator
-
Return values
TemplateTagValueNode
—
parseCallableTemplates()
private
parseCallableTemplates(TokenIterator $tokens) : array<string|int, TemplateTagValueNode>
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
array<string|int, TemplateTagValueNode>
—
parseConditional()
private
parseConditional(TokenIterator $tokens, TypeNode $subjectType) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
$subjectType
: TypeNode
-
-
phpstan-impure
-
Return values
TypeNode
—
parseConditionalForParameter()
private
parseConditionalForParameter(TokenIterator $tokens, string $parameterName) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
$parameterName
: string
-
-
phpstan-impure
-
Return values
TypeNode
—
parseIntersection()
private
parseIntersection(TokenIterator $tokens, TypeNode $type) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
$type
: TypeNode
-
-
phpstan-impure
-
Return values
TypeNode
—
parseNullable()
private
parseNullable(TokenIterator $tokens) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
TypeNode
—
parseObjectShape()
private
parseObjectShape(TokenIterator $tokens) : ObjectShapeNode
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
ObjectShapeNode
—
parseObjectShapeItem()
private
parseObjectShapeItem(TokenIterator $tokens) : ObjectShapeItemNode
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
ObjectShapeItemNode
—
parseObjectShapeKey()
private
parseObjectShapeKey(TokenIterator $tokens) : ConstExprStringNode|IdentifierTypeNode
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
ConstExprStringNode|IdentifierTypeNode
—
parseUnion()
private
parseUnion(TokenIterator $tokens, TypeNode $type) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
$type
: TypeNode
-
-
phpstan-impure
-
Return values
TypeNode
—
subParse()
private
subParse(TokenIterator $tokens) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
phpstan-impure
-
Return values
TypeNode
—
subParseIntersection()
private
subParseIntersection(TokenIterator $tokens, TypeNode $type) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
$type
: TypeNode
-
-
phpstan-impure
-
Return values
TypeNode
—
subParseUnion()
private
subParseUnion(TokenIterator $tokens, TypeNode $type) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
$type
: TypeNode
-
-
phpstan-impure
-
Return values
TypeNode
—
tryParseArrayOrOffsetAccess()
private
tryParseArrayOrOffsetAccess(TokenIterator $tokens, TypeNode $type) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
$type
: TypeNode
-
-
phpstan-impure
-
Return values
TypeNode
—
tryParseCallable()
private
tryParseCallable(TokenIterator $tokens, IdentifierTypeNode $identifier, bool $hasTemplate) : TypeNode
Parameters
-
$tokens
: TokenIterator
-
-
$identifier
: IdentifierTypeNode
-
-
$hasTemplate
: bool
-
-
phpstan-impure
-
Return values
TypeNode
—