CPAINT
[ class tree: CPAINT ] [ index: CPAINT ] [ all elements ]

Class: cpaint

Source Location: /inc/cpaint/cpaint2.inc.php

Class Overview


cpaint base class.


Author(s):

Version:

  • 2.1.0

Copyright:

  • Copyright (c) 2005-2006 Paul Sullivan, Dominique Stender - http://sf.net/projects/cpaint

Variables

Methods



Class Details

[line 40]
cpaint base class.



Tags:

author:  Dominique Stender <dstender@st-webdevelopment.de>
author:  Paul Sullivan <wiley14@gmail.com>
version:  2.1.0
copyright:  Copyright (c) 2005-2006 Paul Sullivan, Dominique Stender - http://sf.net/projects/cpaint
access:  public
usedby:  StatServer


[ Top ]


Class Variables

$api_datatypes =

[line 79]

list of registered complex types used in the CPAINT API



Tags:

access:  protected

Type:   array


[ Top ]

$api_functions =

[line 71]

list of registered methods available through the CPAINT API



Tags:

access:  protected

Type:   array


[ Top ]

$basenode =

[line 63]

the basenode ajaxResponse.



Tags:

access:  protected

Type:   object


[ Top ]

$response_type =

[line 55]

response type.



Tags:

access:  protected

Type:   string


[ Top ]



Class Methods


constructor __construct [line 106]

void __construct( )

PHP 5 constructor.



Tags:

todo:  -o"Dominique Stender" -ccpaint implement a better debugging
access:  public


[ Top ]

constructor cpaint [line 95]

void cpaint( )

PHP4 constructor.



Tags:

access:  public


[ Top ]

method add_node [line 434]

object &add_node( string $nodename, [string $id = ''])

adds a new subnode to the basenode.

will return a reference to it for further processing.




Tags:

access:  public


Parameters:

string   $nodename   name of the new node
string   $id   id of the new node

[ Top ]

method get_attribute [line 501]

string get_attribute( string $name)

retrieves an attribute of the basenode by name.



Tags:

access:  public


Parameters:

string   $name   attribute name

[ Top ]

method get_data [line 455]

mixed get_data( )

returns the data assigned to the basenode.



Tags:

access:  public


[ Top ]

method get_id [line 478]

string get_id( )

gets the id property of the basenode.



Tags:

deprecated:  deprecated since version 2.0.0
access:  public


[ Top ]

method get_name [line 522]

string get_name( )

get name property of the basenode.



Tags:

access:  public


[ Top ]

method get_response_type [line 534]

string get_response_type( )

returns the response type as requested by the client



Tags:

access:  public


[ Top ]

method register [line 308]

boolean register( mixed $func, [string $alias = ''], [array $input = array()], [array $output = array()], [string $comment = ''])

registers a new function or method as part of the CPAINT API



Tags:

version:  1.0.1 16.09.2006 23:07:44 [dstender] Added alias functionality.
access:  public


Parameters:

mixed   $func   function name, array(&$object, 'function_name') or array('class', 'function_name')
string   $alias   alias name for the function. Will be used by the frontend.
array   $input   function input parameters (not yet used by CPAINT and subject to change)
array   $output   function output format (not yed used by CPAINT and subject to change)
string   $comment   description of the functionality

[ Top ]

method return_data [line 225]

void return_data( )

generates and prints the response based on response type supplied by the frontend.



Tags:

access:  public


[ Top ]

method set_attribute [line 490]

void set_attribute( string $name, mixed $value)

adds a new attribute to the basenode.



Tags:

access:  public


Parameters:

string   $name   attribute name
mixed   $value   attribute value

[ Top ]

method set_data [line 445]

void set_data( mixed $data)

assigns textual data to the basenode.



Tags:

access:  public


Parameters:

mixed   $data   data to assign to this node

[ Top ]

method set_id [line 467]

void set_id( string $id)

sets the id property of the basenode.



Tags:

deprecated:  deprecated since version 2.0.0
access:  public


Parameters:

string   $id   the id

[ Top ]

method set_name [line 512]

void set_name( string $name)

set name property of the basenode.



Tags:

access:  public


Parameters:

string   $name   the name

[ Top ]

method start [line 177]

void start( [string $input_encoding = 'UTF-8'])

calls the user function responsible for this specific call.



Tags:

access:  public


Parameters:

string   $input_encoding   input data character encoding, default is UTF-8

[ Top ]

method unregister [line 380]

boolean unregister( string $func)

unregisters a function that is currently part of the CPAINT API.

proves useful when the same set of functions is to be used in the frontend and in some kind of administration environment. you might want to unregister a few (admin) functions for the frontend in this case.

Note that if you supplied an alias when registering a method, you must use the alias to unregister the function / method.




Tags:

version:  1.0.1 16.09.2006 23:10:58 [dstender] Extended PHPDoc for use of aliases.
see:  cpaint:register()
access:  public


Parameters:

string   $func   function name

[ Top ]


Documentation generated on Mon, 03 Aug 2009 21:33:11 +0200 by phpDocumentor 1.4.2