RefMethod
+ Inheritance diagram for RefMethod:

Description

Extracts info from a method.

TODO auto-type based on method name

Protected Properties

MagicType $return
 
- Protected Properties inherited from DocBlockTrait
string[] $warnings = []
 

Public Static Methods

static null self from (ReflectionMethod $method)
 

Public Methods

string __toString ()
 
RefParam[] getParameters ()
 
MagicType getReturnType ()
 Checks for a return tag in the docblock, falls back to checking the reflection. More...
 
void write (RefXML $xml)
 
- Public Methods inherited from RefMemberTrait
RefClass getDeclaringClass ()
 Only use this when class composition doesn't matter. More...
 
self[] getParents ()
 Returns the parents, but only if this member was redeclared from another. More...
 
- Public Methods inherited from VisibilityTrait
string getVisibility ()
 
- Public Methods inherited from MemberInterface
string getVisibility ()
 
bool isStatic ()
 

Additional Inherited Members

- Protected Methods inherited from DocBlockTrait
void writeDocBlock (RefXML $xml, string $docblock)
 Writes the docblock. More...
 
void writeDocBlock_Prune (&$docblock)
 
void writeDocBlock_Tags (RefXML $xml, string &$docblock)
 
void writeDocBlock_Tags_internal (RefXML $xml, string &$docblock)
 
void writeDocBlock_Tags_see (RefXML $xml, string &$docblock)
 
void writeDocBlock_Tags_todo (RefXML $xml, string &$docblock)
 

Methods

◆ __toString()

string __toString ( )
Returns
string Globally unique <ClassFQN>::<identifier>

Implements MemberInterface.

◆ from()

static null self from ( ReflectionMethod  $method)
static
Parameters
ReflectionMethod$method
Returns
null|self Returns null for opaque methods, e.g. Closure::__invoke()

◆ getParameters()

RefParam [] getParameters ( )
Returns
RefParam[]

◆ getReturnType()

MagicType getReturnType ( )

Checks for a return tag in the docblock, falls back to checking the reflection.

Returns
MagicType

◆ write()

void write ( RefXML  $xml)
Parameters
RefXML$xml

Implements XMLWriterInterface.