## Zend_Server_Reflection_Function_Abstract

Description

Function/Method Reflection

Decorates a ReflectionFunction. Allows setting and retrieving an alternate 'service' name (i.e., the name to be used when calling via a service), setting and retrieving the description (originally set using the docblock contents), retrieving the callback and callback type, retrieving additional method invocation arguments, and retrieving the method prototypes.

- usedby: Zend_Server_Reflection_Function
- usedby: Zend_Server_Reflection_Method
- abstract:
- version: $Id: Abstract.php 2815 2007-01-16 01:42:33Z bkarwin $
- license: New BSD License
- copyright: Copyright (c) 2005-2007 Zend Technologies USA Inc. (http://www.zend.com)

Located in /Zend/Server/Reflection/Function/Abstract.php (line 58)

Direct descendents

Class | Description
--- | ---
Zend_Server_Reflection_Function | Function Reflection
Zend_Server_Reflection_Method | Method Reflection

Variable Summary
array $_argv
string $_class
array $_config
string $_description
string $_namespace
array $_prototypes
ReflectionFunction $_reflection
Method Summary
Zend_Server_Reflection_Function_Abstract __construct ( $r, [ $namespace = null], [ $argv = array()])
void getDescription ()
array getInvokeArguments ()
string getNamespace ()
array getPrototypes ()
void setDescription (string $string)
void setNamespace (string $namespace)
void _addTree (Zend_Server_Reflection_Node $parent, [int $level = 0])
array _buildSignatures (array $return, string $returnDesc, $paramTypes, array $paramDesc, array $params)
array _buildTree ()
array _reflect (ReflectionFunction $function)
mixed __call (string $method, array $args)
mixed __get (string $key)
void __set (string $key, mixed $value)
void __wakeup ()
Variables
array $_argv = array() (line 69)

Additional arguments to pass to method on invocation

- access: protected

string $_class (line 84)

Declaring class (needed for when serialization occurs)

- access: protected

Redefined in descendants as:

- Zend_Server_Reflection_Method::$_class : Parent class name

array $_config = array() (line 78)

Used to store extra configuration for the method (typically done by the server class, e.g., to indicate whether or not to instantiate a class).

Associative array; access is as properties via __get() and __set()

- access: protected

string $_description = '' (line 90)

Function/method description

- access: protected

string $_namespace (line 96)

Namespace with which to prefix function/method name

- access: protected

array $_prototypes = array() (line 102)

Prototypes

- access: protected

ReflectionFunction $_reflection (line 63)

- access: protected

Methods
Constructor __construct (line 115)

Constructor

- access: public

Zend_Server_Reflection_Function_Abstract __construct ( $r, [ $namespace = null], [ $argv = array()])

- ReflectionFunction $r
- $namespace
- $argv

Redefined in descendants as:

- Zend_Server_Reflection_Method::__construct() : Constructor

getDescription (line 454)

Retrieve the description

- access: public

void getDescription ()
getInvokeArguments (line 475)

Retrieve additional invocation arguments

- access: public

array getInvokeArguments ()
getNamespace (line 429)

Return method's namespace

- access: public

string getNamespace ()
getPrototypes (line 465)

Retrieve all prototypes as array of Zend_Server_Reflection_Prototypes

- access: public

array getPrototypes ()
setDescription (line 440)

Set the description

- access: public

void setDescription (string $string)

- string $string

setNamespace (line 410)

Set method's namespace

- access: public

void setNamespace (string $namespace)

- string $namespace

_addTree (line 157)

Create signature node tree

Recursive method to build the signature node tree. Increments through each array in $_sigParams, adding every value of the next level to the current value (unless the current value is null).

- access: protected

void _addTree (Zend_Server_Reflection_Node $parent, int $level)

- Zend_Server_Reflection_Node $parent
- int $level

_buildSignatures (line 204)

Build method signatures

Builds method signatures using the array of return types and the array of parameters types

- access: protected

array _buildSignatures (array $return, string $returnDesc, $paramTypes, array $paramDesc, array $params)

- array $return: Array of return types
- string $returnDesc: Return value description
- array $params: Array of arguments (each an array of types)
- array $paramDesc: Array of parameter descriptions
- $paramTypes

_buildTree (line 180)

Build the signature tree

Builds a signature tree starting at the return values and descending through each method argument. Returns an array of Zend_Server_Reflection_Nodes.

- access: protected

array _buildTree ()
_reflect (line 263)

Use code reflection to create method signatures

Determines the method help/description text from the function DocBlock comment. Determines method signatures using a combination of ReflectionFunction and parsing of DocBlock @param and @return values.

- access: protected

array _reflect (ReflectionFunction $function)

- ReflectionFunction $function

__call (line 363)

Proxy reflection calls

- access: public

mixed __call (string $method, array $args)

- string $method
- array $args

__get (line 381)

Retrieve configuration parameters

Values are retrieved by key from $_config. Returns null if no value found.

- access: public

mixed __get (string $key)

- string $key

__set (line 399)

Set configuration parameters

Values are stored by $key in $_config.

- access: public

void __set (string $key, mixed $value)

- string $key
- mixed $value

__wakeup (line 488)

Wakeup from serialization

Reflection needs explicit instantiation to work correctly. Re-instantiate reflection object on wakeup.

- access: public

void __wakeup ()

Redefined in descendants as:

- Zend_Server_Reflection_Method::__wakeup() : Wakeup from serialization

Documentation generated on Wed, 21 Feb 2007 11:45:30 -0800 by phpDocumentor 1.3.1