Class DataHandler

Description

The purpose of this class is to handle the values of elements on our structure for being able to store nodes correctly.

Located in /dataHandlerClass.php (line 62)


	
			
Method Summary
DataHandler __construct (String $nombreTabla, Array $parametros, [Bool $debug = false])
Bool deleteValue ( $path, ElementHandler $ehObject, StructHandler $shObject,  $rhObject, [Bool $debug = false], RelationHandler $rhObject.)
Bool deleteValuesById (Integer $element_id, [Bool $debug = false])
Array getIdsByProperty (Array $array,  $gestorEstructura,  $parametros, [ $debug = false], StructHandler $gestorEstructura., Bool $debug.)
String getTableName ()
String getValue (String $path,  $ehObject,  $shObject,  $rhObject, [Bool $debug = false], ElementHandler $ehObject., StructHandler $shObject., RelationHandler $rhObject.)
Array getValuesFromPath (String $path, StructHandler $shObject, [Bool $debug = false])
Array parsePath (String $path, ElementHandler $ehObject, StructHandler $shObject,  $rhObject, RelationHandler $rhObject.)
Bool setValue (String $path, String $value, ElementHandler $ehObject, StructHandler $shObject,  $rhObject, [Bool $debug = false], RelationHandler $rhObject.)
Methods
Constructor __construct (line 84)

Parameters constructor

DataHandler __construct (String $nombreTabla, Array $parametros, [Bool $debug = false])
  • String $nombreTabla
  • Array $parametros: Array of String. Tags: ['rel_char'] ['id_char'] ['tree_char'] ['root_name']
  • Bool $debug: if true function will throw debug messages as USER_NOTICE
deleteValue (line 392)

This function deletes an atribute from the data table.

  • return: true if a row has been deleted. false if any row has been deleted
  • access: public
Bool deleteValue ( $path, ElementHandler $ehObject, StructHandler $shObject,  $rhObject, [Bool $debug = false], RelationHandler $rhObject.)
deleteValuesById (line 421)

Function that deletes all data of the given id

  • return: true if some row has been deleted.
  • access: public
Bool deleteValuesById (Integer $element_id, [Bool $debug = false])
  • Integer $element_id
  • Bool $debug: if true function will throw debug messages as USER_NOTICE
getIdsByProperty (line 109)

Returns the ids of an attribute with a specific property

  • return: Array of Integer with the elements ids if args are ok. NULL if args not are ok.
  • see: queryHandler (query.php)
Array getIdsByProperty (Array $array,  $gestorEstructura,  $parametros, [ $debug = false], StructHandler $gestorEstructura., Bool $debug.)
  • Array $array: Array of queryHandler.
  • StructHandler $gestorEstructura.
  • Bool $debug.: if true function will throw debug messages as USER_NOTICE
  • $gestorEstructura
  • $parametros
  • $debug
getTableName (line 179)

This function returns the database table's name.

  • return: String with the table's name.
  • access: public
String getTableName ()
getValue (line 232)

This function returns the value of a node with a known path.

  • return: Value of the node returned.
  • access: public
String getValue (String $path,  $ehObject,  $shObject,  $rhObject, [Bool $debug = false], ElementHandler $ehObject., StructHandler $shObject., RelationHandler $rhObject.)
  • String $path: Path of the node to return.
  • ElementHandler $ehObject.
  • StructHandler $shObject.
  • RelationHandler $rhObject.
  • Bool $debug: if true function will throw debug messages as USER_NOTICE
  • $ehObject
  • $shObject
  • $rhObject
getValuesFromPath (line 193)

This function returns all differents values from a given path.

  • return: Array with the values.
  • access: public
Array getValuesFromPath (String $path, StructHandler $shObject, [Bool $debug = false])
  • String $path: Path to extract the information.
  • StructHandler $shObject
  • Bool $debug: if true function will throw debug messages as USER_NOTICE.
parsePath (line 326)

It returns an array composed by each element of the path.

  • return: Array of String composed by each element of the path
  • access: public
Array parsePath (String $path, ElementHandler $ehObject, StructHandler $shObject,  $rhObject, RelationHandler $rhObject.)
setValue (line 281)

This function sets a value of a path.

  • return: It returns true if the value has been written.
  • access: public
Bool setValue (String $path, String $value, ElementHandler $ehObject, StructHandler $shObject,  $rhObject, [Bool $debug = false], RelationHandler $rhObject.)
  • String $path: Path of the node to set the attribute.
  • String $value: Value to write.
  • ElementHandler $ehObject
  • StructHandler $shObject
  • RelationHandler $rhObject.
  • Bool $debug: if true function will throw debug messages as USER_NOTICE
  • $rhObject

Documentation generated by phpDocumentor 1.4.3
Modified by Sergio Barja for S2 - Hierarchical Data Model documentation.