Methods |
public
static
|
createFromName(string $className, non-empty-string $propertyName): self
Create a reflection of a class's property by its name
Create a reflection of a class's property by its name
Throws
|
#
|
public
static
|
createFromInstance(object $instance, non-empty-string $propertyName): self
Create a reflection of an instance's property by its name
Create a reflection of an instance's property by its name
Throws
|
#
|
public
|
__toString(): non-empty-string
|
#
|
public
|
isDefault(): bool
Has the property been declared at compile-time?
Has the property been declared at compile-time?
Note that unless the property is static, this is hard coded to return
true, because we are unable to reflect instances of classes, therefore
we can be sure that all properties are always declared at compile-time.
|
#
|
public
|
getModifiers(): int-mask-of<ReflectionPropertyAdapter::IS_*>
Get the core-reflection-compatible modifier values.
Get the core-reflection-compatible modifier values.
|
#
|
public
|
getName(): non-empty-string
Get the name of the property.
Get the name of the property.
|
#
|
public
|
isPrivate(): bool
Is the property private?
|
#
|
public
|
isProtected(): bool
Is the property protected?
Is the property protected?
|
#
|
public
|
isPublic(): bool
Is the property public?
|
#
|
public
|
isStatic(): bool
Is the property static?
|
#
|
public
|
isPromoted(): bool
|
#
|
public
|
isInitialized($object = null): bool
|
#
|
public
|
isReadOnly(): bool
|
#
|
public
|
getDeclaringClass(): ReflectionClass
|
#
|
public
|
getImplementingClass(): ReflectionClass
|
#
|
public
|
getDocComment(): non-empty-string|null
|
#
|
public
|
hasDefaultValue(): bool
|
#
|
public
|
getDefaultValueExpr(): ?Expr
Deprecated
Use getDefaultValueExpression()
|
#
|
public
|
getDefaultValueExpression(): ?Expr
|
#
|
public
|
getDefaultValue(): mixed
Get the default value of the property (as defined before constructor is
called, when the property is defined)
Get the default value of the property (as defined before constructor is
called, when the property is defined)
Deprecated
Use getDefaultValueExpr()
|
#
|
public
|
isDeprecated(): bool
|
#
|
public
|
getStartLine(): positive-int
Get the line number that this property starts on.
Get the line number that this property starts on.
Throws
|
#
|
public
|
getEndLine(): positive-int
Get the line number that this property ends on.
Get the line number that this property ends on.
Throws
|
#
|
public
|
getStartColumn(): positive-int
|
#
|
public
|
getEndColumn(): positive-int
|
#
|
public
|
getAttributes(): list<ReflectionAttribute>
|
#
|
public
|
getAttributesByName(string $name): list<ReflectionAttribute>
|
#
|
public
|
getAttributesByInstance(class-string $className): list<ReflectionAttribute>
|
#
|
public
|
getValue($object = null): mixed
|
#
|
public
|
setValue(mixed $object, mixed $value = null): void
|
#
|
public
|
allowsNull(): bool
Does this property allow null?
Does this property allow null?
|
#
|
public
|
getType(): ReflectionNamedType|ReflectionUnionType|ReflectionIntersectionType|null
Get the ReflectionType instance representing the type declaration for
this property
Get the ReflectionType instance representing the type declaration for
this property
(note: this has nothing to do with DocBlocks).
|
#
|
public
|
hasType(): bool
Does this property have a type declaration?
Does this property have a type declaration?
(note: this has nothing to do with DocBlocks).
|
#
|