TITAN Library for PHP5  5.1.0
Web Software Development Kit for PHP5
callback Class Reference

Titan Callback Base Class. More...

Inheritance diagram for callback:
extensible_container iterator calendar pdo di_service_container options cache session mssql mysql

Public Member Functions

 __construct ($callback=NULL)
 
 callback ($callback=NULL)
 
 argument ($value)
 
 parameter ($name, $value= '')
 
factory (array $arguments=array())
 
execute ()
 

Protected Member Functions

arguments (array $arguments=array())
 

Detailed Description

Titan Callback Base Class.

Class: \tl\core\callback

Base class that provides callback functionality

Author
James E. Bush work@.nosp@m.bush.nosp@m..cc
Version
5.1.0

Constructor & Destructor Documentation

__construct (   $callback = NULL)

Constructor

Parameters
mixed$callback(optional) The callback function name or array(global object, method) or array(class, static method) to use for each result (default) NULL

If you don't set a callback here, you must set it with the callback() method.

Member Function Documentation

callback (   $callback = NULL)

Set the callback

Parameters
mixed$callback(optional) The callback function name or array(global object, method) or array(class, static method) to use for each result (default) NULL = erase any existing callback
Returns
$this
argument (   $value)

Add an argument or argument variable to the arguments list

Parameters
mixed$valueThe argument or argument variable to add
Returns
callback
parameter (   $name,
  $value = '' 
)

Add a parameter to fill an argument variable to the parameters list

Parameters
string$nameThe parameter to add
mixed$valueThe parameter value
Returns
callback
& arguments ( array  $arguments = array())
protected

Process arguments, replace argument variables with their parameters, if available, and return argument array

Parameters
array$argumentsAn array of arguments or argument variables to pass to the callback
Returns
$arguments
& factory ( array  $arguments = array())

Create and return a new object using the callback as the class name

Used in \tl\core\di_service_container to create an instance object of the service class

Parameters
array$argumentsAn array of arguments or argument variables to pass to the callback
Returns
mixed Object or false
& execute ( )

Execute the callback

Used in child classes to perform the callback

Returns
mixed

The documentation for this class was generated from the following file: