Class: I2CE MagicDataTemplate
This article describes the class I2CE_MagicDataTemplate.
- Extends the class: I2CE_TemplateMeister.
- Parent Classses: I2CE_TemplateMeister I2CE_Fuzzy
- Child Classes:
- Location: Part of the module I2CE in the package I2CE
- Source: Defined in the file lib/I2CE_MagicDataTemplate.php
I2CE_MagicDataTemplate @todo Better documentation.
Variables
$merges
$var protected array $merges;
- Type: protected $merges
Methods
__construct()
I2CE_Template constructor method. This constructor sets up the basic variables for all I2CE_Template objects.
- Signature: public function __construct()
getConfigMetaData()
Gets the metadata of this config file in storage
- Signature: public function getConfigMetaData($storage)
- Parameters:
- I2CE_MagicDataNode $storage
- Default Value: NULL
- I2CE_MagicDataNode $storage
- Returns: boolean
true on sucess
getConfigPath()
Get the path to the current node in the configuration file. Used for error reporting. @param $node DOMElement
- Signature: protected function getConfigPath($node)
- Parameters:
- $node
- Returns: string
The full configuration path
getConfigurationTextContent()
Get the value in the <value> tag of a subnode specfiied by the name attribute
- Signature: public function getConfigurationTextContent($nodeName,$node,$which)
- Parameters:
- Returns: mixed.
Null on failure, a string (the content) on sucess
getDefaultStatus()
Get the default status variables.
- Signature: public function getDefaultStatus()
getMerges()
Get the magic data paths whose status we are tracking. $retrurns array. Keys are paths values are the mergetype
- Signature: public function getMerges()
getTextContent()
Get the text content of a node specified by its tag name
- Signature: public function getTextContent($name,$node,$which)
- Parameters:
- Returns: mixed
string on sucess, null on failure
processStatus()
Assumes that the template is valid. Set the status variables according to this node
- Signature: public function processStatus($configNode,$currentStatus,$vers)
- Parameters:
- DOMNode $configNode
A configuration or conigurationGroup node - $currentStatus
- Default Value: null
- $vers
- Default Value: '0'
- DOMNode $configNode
processValues()
Process values for a config node @param I2CE_MagicDataNode $data @param string $version . Defaults to '0' . The version of the currently loaded data in $storage responsible for this XML @param array of string $paths -- the current path into the $storage that we are using. Defaults to the empty array().
- Signature: public function processValues($configNode,$storage,$status,$vers,$paths)
- Parameters:
- Returns: boolean.
true on sucess
processValues_boolean_single()
Process the value of a configuration of type boolean and single valued
- Signature: protected function processValues_boolean_single($value,$status)
- Parameters:
- Returns: mixed
processValues_delimited_many()
Process the value of a configuration of type delimited and many valued
- Signature: protected function processValues_delimited_many($valueList,$status)
- Parameters:
- Returns: mixed
processValues_delimited_single()
Process the value of a configuration of type delimited and single valued
- Signature: protected function processValues_delimited_single($value,$status)
- Parameters:
- Returns: mixed
processValues_list_many()
Process the value of a configuration of type list and many valued @param array $valueList
- Signature: protected function processValues_list_many($value,$status)
- Parameters:
- $value
- array $status
- Returns: mixed
processValues_list_single()
Process the value of a configuration of type list and single valued
- Signature: protected function processValues_list_single($value,$status)
- Parameters:
- Returns: mixed
processValues_string_many()
Process the value of a configuration of type string and many valued
- Signature: protected function processValues_string_many($valueList,$status)
- Parameters:
- Returns: mixed
processValues_string_single()
Process the value of a configuration of type string and single valued
- Signature: protected function processValues_string_single($value,$status)
- Parameters:
- Returns: mixed
setConfigValues()
Sets the config values from the magic data template @param string $version . Defaults to '0' . The version of the currently loaded data in $storage responsible for this XML @param array of string $paths -- the current path into the $storage that we are using. Defaults to the empty array().
- Signature: public function setConfigValues($config_group,$storage,$status,$vers,$paths)
- Parameters:
- DOMNode $config_group
DomNode of <configurationGroup> - I2CE_MagicData $storage
- array $status
- $vers
- Default Value: '0'
- $paths
- Default Value: array()
- DOMNode $config_group
- Returns: boolean.
Returns true on sucess. False if there was some data that needs to be set in the administration/configuration page.
traversePaths()
- Signature: protected function traversePaths($storage,$paths)
- Parameters:
- $storage
- $paths
updateClassPath()
Update the storage object with the classfile and default classpath. @param $storage I2CE_MagicDataNode @param $module string containing the short module name.
- Signature: protected function updateClassPath($storage,$module)
- Parameters:
- $storage
- Default Value: NULL
- $module
- Default Value: NULL
- $storage
- Returns: boolean
TRUE for success
updatePaths()
Update the list of path elements in MagicData based on attributes of the element passed in: path Contents of this attribute specify an explicit path name If no path element is used then the contents of the name attribute are added to the path. @param $node DOMElement @param $paths array of strings
- Signature: protected function updatePaths($node,$paths)
- Parameters:
- $node
- Default Value: NULL
- &$paths
- Default Value: NULL
- $node
- Returns: boolean
TRUE if no error.
validate()
- Signature: public function validate()
validateValues_string_single()
Valiedates the value of a configuration of type string and single valued
- Signature: protected function validateValues_string_single($value,$status)
- Parameters:
- Returns: mixed
Fuzzy Methods
processValues_color_triple_hex_single()
This method is implemented by I2CE_Module_ColorPicker->processValues_color_triple_hex_single()
processValues_color_triple_hex_many()
This method is implemented by I2CE_Module_ColorPicker->processValues_color_triple_hex_many()
processValues_color_triple_rgb_single()
This method is implemented by I2CE_Module_ColorPicker->processValues_color_triple_rgb_single()
processValues_color_triple_rgb_many()
This method is implemented by I2CE_Module_ColorPicker->processValues_color_triple_rgb_many()
processValues_color_hex_single()
This method is implemented by I2CE_Module_ColorPicker->processValues_color_hex_single()
processValues_color_hex_many()
This method is implemented by I2CE_Module_ColorPicker->processValues_color_hex_many()