Class P4A_Object

Description

The base class extended by every p4a object.

Keeps object identifiers (id, name) and any method for event triggering.

Located in /p4a/p4a_object.php (line 47)


	
			
Direct descendents
Class Description
 class P4A_Data_Source P4A - PHP For Applications.
 class P4A_Collection P4A - PHP For Applications.
 class P4A_Mask The mask is the basic interface object wich contains all widgets and generically every displayed object.
 class P4A_Data_Field Every DATA_SOURCE field is a DATA_FIELD.
 class P4A_Widget Base class for objects that permit user interation with the application.
 class P4A THE APPLICATION.
Variable Summary
 mixed $_helpers
 string $_id
 string $_name
 mixed $_objects
 mixed $_parent_id
Method Summary
 void actionHandler (string $action, [mixed $param = NULL])
 void &build ( $class,  $name)
 void destroy ()
 void dropIntercept ( $action)
 void errorHandler (string $action, [mixed $param = NULL])
 void getId ()
 string getName ()
 string getObjectType ()
 void getParentID ()
 void implementMethod (string $action, object object &$object, string $method)
 void intercept (object object &$object, string $action, [string $method = null])
 boolean isActionTriggered (string $action)
 void p4a_object ([string $name = NULL], [string $prefix = 'obj'], [string $id = NULL])
 void setName ( $name)
 void setParentID ( $object_id)
 void void ([ $params = NULL])
 void _loadHelper ( $name)
 void __call ( $name,  $args)
Variables
mixed $_helpers = array() (line 77)
string $_id = NULL (line 54)

Object's ID

  • access: private
array $_map_actions = array() (line 71)

Keeps the association between an action and its listener.

  • access: private
string $_name = NULL (line 64)

Object's name

  • access: public
mixed $_objects = array() (line 74)
mixed $_parent_id = NULL (line 57)
Methods
actionHandler (line 189)

Handle an action implemented by the object.

  • access: private
void actionHandler (string $action, [mixed $param = NULL])
  • string $action: The action to be handled.
  • mixed $param: Parameter that will be passed to the action handler.
build (line 101)
void &build ( $class,  $name)
  • $class
  • $name
destroy (line 145)

Destroys the object Retrieves all children objects and destroy them.

  • access: public
void destroy ()
dropIntercept (line 220)
void dropIntercept ( $action)
  • $action
errorHandler (line 272)

Handle an error action implemented by the object.

Checks if the the specified action is triggered and calls it, if the action is not triggered calls the general error handler for the object.

  • access: private
void errorHandler (string $action, [mixed $param = NULL])
  • string $action: The action to be handled.
  • mixed $param: Parameter that will be passed to the error handler.
getId (line 135)
void getId ()
getName (line 178)

Returns the object name.

  • see: $name
  • access: public
string getName ()
getObjectType (line 258)

Returns the "CLASS" type of the object.

  • access: public
string getObjectType ()
getParentID (line 129)
void getParentID ()
implementMethod (line 233)

Wrapper for setting an intercepted event on an object.

  • access: public
void implementMethod (string $action, object object &$object, string $method)
  • string $action: The action's name.
  • object object &$object: The object that will intercept the action.
  • string $method: The method that will be called.
intercept (line 212)

Tells an object to execute a method when an action is called.

  • access: public
void intercept (object object &$object, string $action, [string $method = null])
  • object object &$object: The object that has the method.
  • string $action: The action triggered by an event.
  • string $method: The method that will be executed.
isActionTriggered (line 244)

Tells if an action is triggered.

  • access: public
boolean isActionTriggered (string $action)
  • string $action: The action.
p4a_object (line 88)

Class constructor.

Sets default properties and store the object in the application object stack.

  • access: private
void p4a_object ([string $name = NULL], [string $prefix = 'obj'], [string $id = NULL])
  • string $name: Object identifier, when you add an object to another object (such as $p4a) you can access to it by $p4a->object_name.
  • string $prefix: Prefix string for ID generation.
  • string $id: Object ID identifies an object in the $p4a's object collection. You can set a static ID if you want that all clients uses the same ID (tipically for web sites).
setName (line 167)

Sets the object's name.

  • access: public
void setName ( $name)
  • $name
setParentID (line 123)
void setParentID ( $object_id)
  • $object_id
void (line 306)
void void ([ $params = NULL])
  • $params
_loadHelper (line 312)
void _loadHelper ( $name)
  • $name
__call (line 342)
void __call ( $name,  $args)
  • $name
  • $args

Documentation generated on Mon, 07 Jan 2008 11:29:28 +0100 by phpDocumentor 1.4.0