Class TemplateConfigFile

Description

Utility class used to parse and load template config variables

PHP2Go's template engine is able to load variables from configuration files written in the .ini format. This class is used to parse these files, extracting sections and variables from it.

For each script execution, the framework will use one single instance of this class.

Located in /core/template/TemplateConfigFile.class.php (line 46)

PHP2Go
   |
   --TemplateConfigFile
Variable Summary
Method Summary
TemplateConfigFile TemplateConfigFile (Template &$Template, [array $options = array()])
array get (string $filePath, [string $section = NULL])
void loadFile (string $filePath)
string _parseContents (string $contents)
Variables
array $data = array() (line 54)

Parsed config variables

  • access: private
array $options = array() (line 62)

Parsing settings

  • access: private
Template $_Template = NULL (line 70)

Owner template

  • access: private
Methods
Constructor TemplateConfigFile (line 79)

Class constructor

TemplateConfigFile TemplateConfigFile (Template &$Template, [array $options = array()])
  • Template &$Template: Owner template
  • array $options: Options
get (line 97)

Get all variables or a section from a file

array get (string $filePath, [string $section = NULL])
  • string $filePath: Config file path
  • string $section: Section name
loadFile (line 117)

Loads a new configuration file

void loadFile (string $filePath)
  • string $filePath: File path
_parseContents (line 160)

Parse contents of a configuration file

  • access: private
string _parseContents (string $contents)
  • string $contents: File contents

Inherited Methods

Inherited From PHP2Go

PHP2Go::PHP2Go()
PHP2Go::equals()
PHP2Go::generateUniqueId()
PHP2Go::getClassName()
PHP2Go::getConfigVal()
PHP2Go::getLangVal()
PHP2Go::getObjectName()
PHP2Go::getParentName()
PHP2Go::hasDestructor()
PHP2Go::hashCode()
PHP2Go::isA()
PHP2Go::isSubclassOf()
PHP2Go::logError()
PHP2Go::raiseError()
PHP2Go::registerDestructor()
PHP2Go::registerShutdownFunc()
PHP2Go::retrieve()
PHP2Go::store()
PHP2Go::__toString()

Documentation generated on Sun, 07 Oct 2007 19:30:20 -0300 by phpDocumentor 1.3.2