API Documentation

Server/Reflection/Function/Abstract.php

Includes Classes 
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Server
Classes
Zend_Server_Reflection_Function_Abstract

Description

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

Zend_Server_Reflection_Function_Abstract

category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Server
subpackage
Reflection
version
$Id: Abstract.php 20637 2010-01-25 22:33:22Z matthew $
Properties
$_reflection
$_argv
$_config
$_class
$_description
$_namespace
$_prototypes
$_return
$_returnDesc
$_paramDesc
$_sigParams
$_sigParamsDepth
Methods
__construct
_addTree
_buildTree
_buildSignatures
_reflect
__call
__get
__set
setNamespace
getNamespace
setDescription
getDescription
getPrototypes
getInvokeArguments
__wakeup

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 {@link Zend_Server_Reflection_Prototype prototypes}.

Properties

$_argv

array $_argv = 'array'

Additional arguments to pass to method on invocation

Details

$_argv
array
visibility
protected
default
array
final
false
static
false

$_class

string $_class = ''

Declaring class (needed for when serialization occurs)

Details

$_class
string
visibility
protected
default
final
false
static
false

$_config

array $_config = 'array'

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 {@link __get()} and {@link __set()}

Details

$_config
array
visibility
protected
default
array
final
false
static
false

$_description

string $_description = ''

Function/method description

Details

$_description
string
visibility
protected
default
final
false
static
false

$_namespace

string $_namespace = ''

Namespace with which to prefix function/method name

Details

$_namespace
string
visibility
protected
default
final
false
static
false

$_paramDesc

 $_paramDesc = ''

Details

visibility
private
default
final
false
static
false

$_prototypes

array $_prototypes = 'array'

Prototypes

Details

$_prototypes
array
visibility
protected
default
array
final
false
static
false

$_reflection

ReflectionFunction $_reflection = ''

Details

$_reflection
ReflectionFunction
visibility
protected
default
final
false
static
false

$_return

 $_return = ''

Details

visibility
private
default
final
false
static
false

$_returnDesc

 $_returnDesc = ''

Details

visibility
private
default
final
false
static
false

$_sigParams

 $_sigParams = ''

Details

visibility
private
default
final
false
static
false

$_sigParamsDepth

 $_sigParamsDepth = ''

Details

visibility
private
default
final
false
static
false

Methods

__call

__call( string $method, array $args ) : mixed

Proxy reflection calls

Arguments
$method
string
$args
array
Output
mixed
Details
visibility
public
final
false
static
false

__construct

__construct( ReflectionFunction $r,  $namespace = null,  $argv = array ) :

Constructor

Arguments
$r
ReflectionFunction
$namespace
$argv
Details
visibility
public
final
false
static
false

__get

__get( string $key ) : mixed

Retrieve configuration parameters

Values are retrieved by key from {@link $_config}. Returns null if no value found.

Arguments
$key
string
Output
mixed
Details
visibility
public
final
false
static
false

__set

__set( string $key, mixed $value ) : void

Set configuration parameters

Values are stored by $key in {@link $_config}.

Arguments
$key
string
$value
mixed
Details
visibility
public
final
false
static
false

__wakeup

__wakeup( ) : void

Wakeup from serialization

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

Details
visibility
public
final
false
static
false

_addTree

_addTree( Zend_Server_Reflection_Node $parent, int $level = 0 ) : void

Create signature node tree

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

Arguments
$parent
Zend_Server_Reflection_Node
$level
int
Details
visibility
protected
final
false
static
false

_buildSignatures

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

Build method signatures

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

Arguments
$return
array
Array of return types
$returnDesc
string
Return value description
$paramTypes
$paramDesc
array
Array of parameter descriptions
Output
array
Details
visibility
protected
final
false
static
false

_buildTree

_buildTree( ) : array

Build the signature tree

Builds a signature tree starting at the return values and descending through each method argument. Returns an array of {@link Zend_Server_Reflection_Node}s.

Output
array
Details
visibility
protected
final
false
static
false

_reflect

_reflect( ) : array

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.

Output
array
Details
visibility
protected
final
false
static
false

getDescription

getDescription( ) : void

Retrieve the description

Details
visibility
public
final
false
static
false

getInvokeArguments

getInvokeArguments( ) : array

Retrieve additional invocation arguments

Output
array
Details
visibility
public
final
false
static
false

getNamespace

getNamespace( ) : string

Return method's namespace

Output
string
Details
visibility
public
final
false
static
false

getPrototypes

getPrototypes( ) : array

Retrieve all prototypes as array of {@link Zend_Server_Reflection_Prototype Zend_Server_Reflection_Prototypes}

Output
array
Details
visibility
public
final
false
static
false

setDescription

setDescription( string $string ) : void

Set the description

Arguments
$string
string
Details
visibility
public
final
false
static
false

setNamespace

setNamespace( string $namespace ) : void

Set method's namespace

Arguments
$namespace
string
Details
visibility
public
final
false
static
false
Documentation was generated by DocBlox.