Reflection for determining method signatures to use with server classes

package Default

 Methods

Perform class reflection to create dispatch signatures

reflectClass(string|object $class, boolean|array $argv = false, string $namespace = '') : \Zend\Server\Reflection\ReflectionClass
Static

Creates a \Zend\Server\Reflection\ClassReflection object for the class or object provided.

If extra arguments should be passed to dispatchable methods, these may be provided as an array to $argv.

Parameters

$class

stringobject

Class name or object

$argv

booleanarray

Optional arguments to be used during the method call

$namespace

string

Optional namespace with which to prefix the method name (used for the signature key). Primarily to avoid collisions, also for XmlRpc namespacing

Exceptions

\Zend\Server\Reflection\Exception\InvalidArgumentException

Returns

\Zend\Server\Reflection\ReflectionClass

Perform function reflection to create dispatch signatures

reflectFunction(string $function, boolean|array $argv = false, string $namespace = '') : \Zend\Server\Reflection\ReflectionFunction
Static

Creates dispatch prototypes for a function. It returns a \Zend\Server\Reflection\FunctionReflection object.

If extra arguments should be passed to the dispatchable function, these may be provided as an array to $argv.

Parameters

$function

string

Function name

$argv

booleanarray

Optional arguments to be used during the method call

$namespace

string

Optional namespace with which to prefix the function name (used for the signature key). Primarily to avoid collisions, also for XmlRpc namespacing

Exceptions

\Zend\Server\Reflection\Exception\InvalidArgumentException

Returns

\Zend\Server\Reflection\ReflectionFunction