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

Class: Config_Container_GenericConf

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

Class Overview

Config_Container
   |
   --Config_Container_GenericConf

Config parser for generic .conf files like htdig.conf...


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 generic .conf files like htdig.conf...


[ Top ]


Class Variables

$options = array(
               'comment' => '#',
               'equals'  => ':',
               'newline' => '\\')

[line 36]

Use options to specify your .conf specificities ie, comment char, equal sign, config line feed.

Type:   array
Overrides:   Array


[ Top ]



Method Detail

parseDatasrc   [line 48]

mixed &parseDatasrc( string $datasrc)

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 93]

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:40 +0200 by phpDocumentor 1.2.3. PEAR Logo Copyright © PHP Group 2004.