Class TApplicationConfiguration

Description

TApplicationConfiguration class.

This class is used internally by TApplication to parse and represent application configuration.

  • since: 3.0
  • version: $Id: TApplication.php 2244 2007-09-26 13:15:56Z xue $
  • author: Qiang Xue <qiang.xue@gmail.com>

Located in /TApplication.php (line 1149)

TComponent
   |
   --TApplicationConfiguration
Method Summary
array getAliases ()
boolean getIsEmpty ()
array getModules ()
array getParameters ()
array getProperties ()
array getServices ()
array getUsings ()
void loadExternalXml (TXmlElement $includeNode, string $configPath)
void loadFromFile (string $fname)
void loadFromXml (TXmlElement $dom, string $configPath)
void loadModulesXml (TXmlElement $modulesNode, string $configPath)
void loadParametersXml (TXmlElement $parametersNode, string $configPath)
void loadPathsXml (TXmlElement $pathsNode, string $configPath)
void loadServicesXml (TXmlElement $servicesNode, string $configPath)
Methods
getAliases (line 1409)

Returns list of path alias definitions.

The definitions are aggregated (top-down) from configuration files along the path to the specified page. Each array element represents a single alias definition, with the key being the alias name and the value the absolute path.

  • return: list of path alias definitions
  • access: public
array getAliases ()
getExternalConfigurations (line 1473)
  • return: list of external configuration files. Each element is like $filePath=>$condition
  • access: public
array getExternalConfigurations ()
getIsEmpty (line 1199)
  • return: whether this configuration contains actual stuff
  • access: public
boolean getIsEmpty ()
getModules (line 1440)

Returns list of module configurations.

The module configurations are aggregated (top-down) from configuration files along the path to the specified page. Each array element represents a single module configuration, with the key being the module ID and the value the module configuration. Each module configuration is stored in terms of an array with the following content ([0]=>module type, [1]=>module properties, [2]=>complete module configuration) The module properties are an array of property values indexed by property names. The complete module configuration is a TXmlElement object representing the raw module configuration which may contain contents enclosed within module tags.

  • return: list of module configurations to be used
  • access: public
array getModules ()
getParameters (line 1465)

Returns list of parameter definitions.

The parameter definitions are aggregated (top-down) from configuration files along the path to the specified page. Each array element represents a single parameter definition, with the key being the parameter ID and the value the parameter definition. A parameter definition can be either a string representing a string-typed parameter, or an array. The latter defines a component-typed parameter whose format is as follows, ([0]=>component type, [1]=>component properties) The component properties are an array of property values indexed by property names.

  • return: list of parameter definitions to be used
  • access: public
array getParameters ()
getProperties (line 1397)

Returns list of page initial property values.

Each array element represents a single property with the key being the property name and the value the initial property value.

  • return: list of page initial property values
  • access: public
array getProperties ()
getServices (line 1448)
  • return: list of service configurations
  • access: public
array getServices ()
getUsings (line 1421)

Returns list of namespaces to be used.

The namespaces are aggregated (top-down) from configuration files along the path to the specified page. Each array element represents a single namespace usage, with the value being the namespace to be used.

  • return: list of namespaces to be used
  • access: public
array getUsings ()
loadExternalXml (line 1378)

Loads the external XML configurations.

  • access: protected
void loadExternalXml (TXmlElement $includeNode, string $configPath)
  • TXmlElement $includeNode: the application DOM element
  • string $configPath: the context path (for specifying relative paths)
loadFromFile (line 1189)

Parses the application configuration file.

  • access: public
  • throws: TConfigurationException if there is any parsing error
void loadFromFile (string $fname)
  • string $fname: configuration file name
loadFromXml (line 1209)

Parses the application configuration given in terms of a TXmlElement.

  • access: public
void loadFromXml (TXmlElement $dom, string $configPath)
  • TXmlElement $dom: the XML element
  • string $configPath: the context path (for specifying relative paths)
loadModulesXml (line 1295)

Loads the modules XML node.

  • access: protected
void loadModulesXml (TXmlElement $modulesNode, string $configPath)
  • TXmlElement $modulesNode: the modules XML node
  • string $configPath: the context path (for specifying relative paths)
loadParametersXml (line 1348)

Loads the parameters XML node.

  • access: protected
void loadParametersXml (TXmlElement $parametersNode, string $configPath)
  • TXmlElement $parametersNode: the parameters XML node
  • string $configPath: the context path (for specifying relative paths)
loadPathsXml (line 1249)

Loads the paths XML node.

  • access: protected
void loadPathsXml (TXmlElement $pathsNode, string $configPath)
  • TXmlElement $pathsNode: the paths XML node
  • string $configPath: the context path (for specifying relative paths)
loadServicesXml (line 1323)

Loads the services XML node.

  • access: protected
void loadServicesXml (TXmlElement $servicesNode, string $configPath)
  • TXmlElement $servicesNode: the services XML node
  • string $configPath: the context path (for specifying relative paths)

Inherited Methods

Inherited From TComponent

TComponent::addParsedObject()
TComponent::attachEventHandler()
TComponent::canGetProperty()
TComponent::canSetProperty()
TComponent::createdOnTemplate()
TComponent::detachEventHandler()
TComponent::evaluateExpression()
TComponent::evaluateStatements()
TComponent::getEventHandlers()
TComponent::getSubProperty()
TComponent::hasEvent()
TComponent::hasEventHandler()
TComponent::hasProperty()
TComponent::raiseEvent()
TComponent::setSubProperty()
TComponent::__get()
TComponent::__set()

Documentation generated on Mon, 21 Apr 2008 11:30:28 -0400 by phpDocumentor 1.3.0RC4