Config
[ class tree: Config ] [ index: Config ] [ all elements ]

Class: Config_Container_PHPArray

Source Location: /Config-1.0/Config/Container/PHPArray.php

Class Overview

Config_Container
   |
   --Config_Container_PHPArray

Config parser for common PHP configuration array such as found in the horde project.


Author(s):

Variables

Methods


Inherited Variables

Inherited Methods

Class: Config_Container

Config_Container::Config_Container()
Constructor
Config_Container::addItem()
Adds an item to this item.
Config_Container::getContent()
Get this item's content.
Config_Container::getItem()
Tries to find the specified item(s) and returns the objects.
Config_Container::getItemIndex()
Returns the item position in its parent children array.
Config_Container::getName()
Get this item's name.
Config_Container::getParent()
Returns the item parent object.
Config_Container::getType()
Get this item's type.
Config_Container::insertItem()
Inserts an item to a specified position.
Config_Container::removeItem()
Deletes an item (section, directive, comment...) from the current object
Config_Container::setContent()
Set this item's content.
Config_Container::setName()
Set this item's name.
Config_Container::setOptions()
Imports the requested options if allowed
Config_Container::setType()
Set this item's type.
Config_Container::toArray()
Returns a key/value pair array of the container and its children.
Config_Container::toString()
Interface method
Config_Container::writeDatasrc()
Writes the configuration to a file Must be overriden in case you don't use files.

Class Details

[line 29]
Config parser for common PHP configuration array such as found in the horde project.


[ Top ]


Class Variables

$options = array('name' => 'conf')

[line 36]

Use options to specify the name of your configuration array.

It defaults to $conf.


Type:   array
Overrides:   Array


[ Top ]



Method Detail

parseDatasrc   [line 45]

mixed &parseDatasrc( string $datasrc, [mixed $first = true])

Parses the data of the given configuration file
  • Return: returns a PEAR_ERROR, if error occurs or the container itsef
  • Access: public

Parameters:

string   $datasrc     path to the configuration file

[ Top ]

toString   [line 89]

string toString( )

Returns a formatted string of the object
  • Access: public

Overrides Config_Container::toString() (Interface method)
[ Top ]


Documentation generated on Fri, 30 Apr 2004 21:44:42 +0200 by phpDocumentor 1.2.3. PEAR Logo Copyright © PHP Group 2004.