wCMF
3.6
|
Public Member Functions | |
Table ($type, $oid=null) | |
reIndex () | |
getNumRows () | |
getColumns () | |
getRow ($index) | |
getColumn ($name) | |
insertRow ($index=null, $values=array()) | |
deleteRow ($index) | |
getValueProperties ($name, $type=null) | |
setValueProperties ($name, $properties, $type=null) | |
![]() | |
PersistentObject ($type, $oid=null) | |
getType () | |
setType ($type) | |
getBaseType () | |
getOID () | |
getBaseOID () | |
setOID ($oid) | |
getDBID () | |
setDBID ($id) | |
& | getMapper () |
& | getDataConverter () |
save () | |
delete ($recursive=true) | |
getState () | |
setState ($state, $recursive=true) | |
setImmutable () | |
getLock () | |
& | duplicate () |
copyValues (&$object, $dataTypes=array(), $copyPkValues=true) | |
copyValueIntern (&$node, $valueName, $dataType, &$targetNode, $dataTypes, $valuesToIgnore) | |
clearValues ($dataTypes=array()) | |
clearValueIntern (&$node, $valueName, $dataType, $dataTypes) | |
updateOID () | |
afterCreate () | |
beforeInsert () | |
afterInsert () | |
afterLoad () | |
beforeUpdate () | |
afterUpdate () | |
beforeDelete () | |
afterDelete () | |
hasValue ($name, $type=null) | |
getValue ($name, $type=null) | |
removeValue ($name, $type=null) | |
getUnconvertedValue ($name, $type=null) | |
getConvertedValue ($name, $type=null) | |
getValueTypes ($name) | |
validateValues () | |
validateValueIntern (&$node, $valueName, $dataType, &$errorMsg) | |
validateValue ($name, $value, $type=null) | |
validateValueAgainstRestrictions ($name, $value, $type=null) | |
setValue ($name, $value, $type=null, $forceSet=false) | |
getValueProperties ($name, $type=null) | |
setValueProperties ($name, $properties, $type=null) | |
getValueProperty ($name, $property, $type=null) | |
setValueProperty ($name, $property, $value, $type=null) | |
getValueNames ($type=null) | |
getDataTypes () | |
getProperty ($name) | |
setProperty ($name, $value) | |
getPropertyNames () | |
addChangeListener (&$listener) | |
removeChangeListener (&$listener) | |
propagateValueChange ($name, $type, $oldValue, $newValue) | |
propagatePropertyChange ($name, $oldValue, $newValue) | |
propagateStateChange ($oldValue, $newValue) | |
getObjectDisplayName () | |
getObjectDescription () | |
getDisplayValue () | |
getValueDisplayName ($name, $type=null) | |
getValueDescription ($name, $type=null) | |
toString ($verbose=false) | |
isIndexInSearch () | |
![]() | |
getClassDefinitionFiles () | |
loadFromSession () | |
saveToSession () | |
Public Attributes | |
$_valueProperties = array() | |
![]() | |
$_oid = null | |
$_type = '' | |
$_data = array() | |
$_properties = array() | |
$_state = STATE_CLEAN | |
$_isImmutable = false | |
$_changeListeners = array() | |
Table is a PersistentObject that holds a table structure. The rows of the table correspond to the value names of the PersistentObject and the columns to the datatypes. So if you want to set the value of row $i and column $j to $value call $table->setValue($i, $value, $j). To retrieve the corresponding value call $value = $table->getValue($i, $j).
wCMF - wemove Content Management Framework Copyright (C) 2005-2014 wemove digital solutions GmbH
Licensed under the terms of any of the following licenses at your choice:
See the license.txt file distributed with this work for additional information.
Definition at line 34 of file class.Table.php.
Table::Table | ( | $type, | |
$oid = null |
|||
) |
Constructor.
type | The Tables type. |
oid | The Tables oid (, optional will be calculated if not given or not valid). |
Definition at line 42 of file class.Table.php.
References PersistenceFacade\composeOID(), PersistenceFacade\isValidOID(), PersistentObject\setState(), STATE_CLEAN, and STATE_NEW.
Table::reIndex | ( | ) |
Reset all row indizes to an ascending sequence starting by 0.
Definition at line 62 of file class.Table.php.
References getColumns().
Table::getNumRows | ( | ) |
Get all row names of the table.
Definition at line 71 of file class.Table.php.
References getColumns(), and PersistentObject\getValueNames().
Referenced by getColumn(), and insertRow().
Table::getColumns | ( | ) |
Get all column names of the table.
Definition at line 80 of file class.Table.php.
References PersistentObject\getDataTypes().
Referenced by deleteRow(), getNumRows(), getRow(), insertRow(), and reIndex().
Table::getRow | ( | $index | ) |
Get all column values of a row.
index | The index of the row (zero based). |
Definition at line 89 of file class.Table.php.
References getColumns(), and PersistentObject\getValue().
Table::getColumn | ( | $name | ) |
Get all row values of a column.
name | The name of the cloumn. |
Definition at line 102 of file class.Table.php.
References getNumRows(), and PersistentObject\getValue().
Table::insertRow | ( | $index = null , |
|
$values = array() |
|||
) |
Insert a new row before a given row.
index | The index of the row before which the new row should be inserted (zero based) [maybe null]. |
values | An assoziative array with column name keys and values to insert. If the name is empty or does not exist the row will be appended to the end of the table. |
Definition at line 117 of file class.Table.php.
References getColumns(), getNumRows(), PersistentObject\setState(), and STATE_DIRTY.
Table::deleteRow | ( | $index | ) |
Remove a row.
index | The index of the row to remove (zero based). |
Definition at line 139 of file class.Table.php.
References getColumns(), PersistentObject\setState(), and STATE_DIRTY.
Table::getValueProperties | ( | $name, | |
$type = null |
|||
) |
Definition at line 150 of file class.Table.php.
Table::setValueProperties | ( | $name, | |
$properties, | |||
$type = null |
|||
) |
Definition at line 162 of file class.Table.php.
References PersistentObject\setState(), and STATE_DIRTY.
Table::$_valueProperties = array() |
Definition at line 36 of file class.Table.php.