mediatekformation

StaticReflectionService
in package
implements ReflectionService

PHP Runtime Reflection Service.

Interfaces, Classes, Traits and Enums

ReflectionService
Very simple reflection service abstraction.

Table of Contents

getAccessibleProperty()  : ReflectionProperty|null
Returns an accessible property (setAccessible(true)) or null.
getClass()  : null
Returns a reflection class instance or null.
getClassNamespace()  : string
getClassShortName()  : string
Returns the shortname of a class.
getParentClasses()  : array<string|int, string>
Returns an array of the parent classes (not interfaces) for the given class.
hasPublicMethod()  : bool
Checks if the class have a public method with the given name.

Methods

getAccessibleProperty()

Returns an accessible property (setAccessible(true)) or null.

public getAccessibleProperty(mixed $class, mixed $property) : ReflectionProperty|null
Parameters
$class : mixed
$property : mixed
Return values
ReflectionProperty|null

getClass()

Returns a reflection class instance or null.

public getClass(mixed $class) : null
Parameters
$class : mixed
Return values
null

getClassNamespace()

public getClassNamespace(mixed $className) : string
Parameters
$className : mixed
Return values
string

getClassShortName()

Returns the shortname of a class.

public getClassShortName(mixed $className) : string
Parameters
$className : mixed
Return values
string

getParentClasses()

Returns an array of the parent classes (not interfaces) for the given class.

public getParentClasses(mixed $class) : array<string|int, string>
Parameters
$class : mixed
Return values
array<string|int, string>

hasPublicMethod()

Checks if the class have a public method with the given name.

public hasPublicMethod(mixed $class, mixed $method) : bool
Parameters
$class : mixed
$method : mixed
Return values
bool

Search results