XCube_DelegateManager Class Reference

List of all members.

Public Member Functions

 register ($name, &$delegate)
 add ($name, $callback, $param3=null, $param4=null)
 delete ($name, $delcallback)
 reset ($name)
 getDelegates ()

Detailed Description

This is the agent of un-registered delegate objects. Usually, connected functions can't be added to un-registered delegates. When destination delegates are un-registered yet, this manager is keeping those functions and parameters until the destination delegate will be registered.

In other words, this class realizes lazy delegate registering.


Member Function Documentation

XCube_DelegateManager::register ( name,
&$  delegate 
)

Add $delegate as Delegate to the list of this manager. If some functions that want to connect to $delegate, have been entrusted yet, this object calls add() of $delegate with their parameters.

Usually this member function isn't used as Cube's API by developers. In many cases, XCube_Delegate::register() calls this.

public

XCube_DelegateManager::add ( name,
callback,
param3 = null,
param4 = null 
)

Connect any functions to the delegate that have the specified name. If there aren't any delegates that have the specified name, this manager entrust parameters to member properties. Then, when the delegate that have the specified name will be registered, this manager will set these parameters to the delegate.

public

Parameters:
$name register name
See also:
XCube_Delegate::add()

XCube_DelegateManager::delete ( name,
delcallback 
)

Disconnect a function from the delegate that have the specified name.

public

Parameters:
$name register name
See also:
XCube_Delegate::delete()

XCube_DelegateManager::reset ( name  ) 

Reset all functions off the delegate that have the specified name.

public

See also:
XCube_Delegate::reset()

XCube_DelegateManager::getDelegates (  ) 

public

Returns:
array of XCube_Delegate


The documentation for this class was generated from the following file:
Generated on Thu Nov 2 00:27:22 2006 for XOOPS Cube Legacy by  doxygen 1.5.1