Class ValueObject

Description

ValueObject implements the a list data structure.

It provides basic getters and manipulators to an internal data storage.

Located in /valueobject.php (line 15)

PHOOL
   |
   --ValueObject
Direct descendents
Class Description
Resource Class Resource is an abstract persistance Adapter for HTTP Services
DbTable Class DbTable is an implementation of the DAO pattern for database tables.
Request An Anonymous request Object
Variable Summary
array $data
Method Summary
ValueObject ValueObject ([mixed $values = false])
void clear ()
void erase (scalar $k)
mixed &get (mixed $k)
array get_all ()
array get_keys ()
int get_size ()
string get_type (mixed $key)
boolean has (scalar $k)
void set (scalar $k, mixed $v)
void set_all ([array $values = array( )])
Variables
array $data (line 22)

Internal value container

  • access: protected

Inherited Variables

Inherited from PHOOL

PHOOL::$debug
PHOOL::$errorlabels
PHOOL::$errorlevels
PHOOL::$errors
PHOOL::$exists
PHOOL::$logdir
PHOOL::$loglevel
PHOOL::$objname
Methods
Constructor ValueObject (line 32)

Construct a ValueObject object

If values are in an object, all readable properties from get_objects_vars() are set as internal values

ValueObject ValueObject ([mixed $values = false])
  • mixed $values: container data
clear (line 137)

Reset internal data container

void clear ()
erase (line 128)

unset a key in th internal container

void erase (scalar $k)
  • scalar $k: key
get (line 63)

Get a specific value from the internal data container

  • return: value
mixed &get (mixed $k)
  • mixed $k: key
get_all (line 80)

Get the whole data container (by copy)

array get_all ()
get_keys (line 148)

Get all keys of internal data container

array get_keys ()
get_size (line 169)

Get size of internal data container

int get_size ()
get_type (line 159)

Get type of an internal value

  • return: datatype
string get_type (mixed $key)
  • mixed $key: key
has (line 117)

Test if a key is available

boolean has (scalar $k)
  • scalar $k: keyname
set (line 92)

Save a value to the internal container

void set (scalar $k, mixed $v)
  • scalar $k: key
  • mixed $v: value
set_all (line 103)

Save multiple values

void set_all ([array $values = array( )])
  • array $values: values to set

Inherited Methods

Inherited From PHOOL

PHOOL::PHOOL()
PHOOL::debug()
PHOOL::error()
PHOOL::get_errors()
PHOOL::handle_error()
PHOOL::has_error()
PHOOL::log_error()
PHOOL::set_debug()
PHOOL::set_logdir()
PHOOL::set_loglevel()
Class Constants

Inherited Constants

Inherited from PHOOL

PHOOL::ERROR
PHOOL::UNKNOWN
PHOOL::USER
PHOOL::WARNING

Documentation generated on Tue, 12 May 2009 23:09:43 +0200 by phpDocumentor 1.4.1