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

Class: ConfigHandler

Source Location: /config/ConfigHandler.class.php

Class Overview

ParameterHolder
   |
   --ConfigHandler

ConfigHandler allows a developer to create a custom formatted configuration file pertaining to any information they like and still have it auto-generate PHP code.


Author(s):

  • Sean Kerr (skerr@mojavi.org)

Version:

  • $Id: ConfigHandler.class.php 707 2004-12-28 17:48:28Z seank $

Copyright:

Methods


Child classes:

LoggingConfigHandler
CompileConfigHandler
CompileConfigHandler gathers multiple files and puts them into a single file.
IniConfigHandler
IniConfigHandler is a base class for .ini configuration handlers. This class provides a central location for parsing ini files and detecting required categories.

Inherited Variables

Inherited Methods

Class: ParameterHolder

ParameterHolder::clearParameters()
Clear all parameters associated with this request.
ParameterHolder::getParameter()
Retrieve a parameter.
ParameterHolder::getParameterNames()
Retrieve an array of parameter names.
ParameterHolder::getParameters()
Retrieve an array of parameters.
ParameterHolder::hasParameter()
Indicates whether or not a parameter exists.
ParameterHolder::removeParameter()
Remove a parameter.
ParameterHolder::setParameter()
Set a parameter.
ParameterHolder::setParameterByRef()
Set a parameter by reference.
ParameterHolder::setParameters()
Set an array of parameters.
ParameterHolder::setParametersByRef()
Set an array of parameters by reference.

Class Details

[line 25]
ConfigHandler allows a developer to create a custom formatted configuration file pertaining to any information they like and still have it auto-generate PHP code.



Tags:

abstract:  
version:  $Id: ConfigHandler.class.php 707 2004-12-28 17:48:28Z seank $
since:  3.0.0
copyright:  (c) Sean Kerr, http://www.mojavi.org
author:  Sean Kerr (skerr@mojavi.org)


[ Top ]


Class Methods


method addReplacement [line 43]

void addReplacement( string $oldValue, string $newValue)

Add a set of replacement values.



Tags:

access:  public
since:  3.0.0
author:  Sean Kerr (skerr@mojavi.org)


Parameters:

string   $oldValue   The old value.
string   $newValue   The new value which will replace the old value.

[ Top ]

method execute [line 68]

string &execute( string $config)

Execute this configuration handler.



Tags:

return:  Data to be written to a cache file.
abstract:  
since:  3.0.0
author:  Sean Kerr (skerr@mojavi.org)
throws:  ConfigurationException If a requested configuration file does not exist or is not readable.
throws:  ParseException If a requested configuration file is improperly formatted.


Overridden in child classes as:

LoggingConfigHandler::execute()
Execute this configuration handler.
CompileConfigHandler::execute()
Execute this configuration handler.
DatabaseConfigHandler::execute()
Execute this configuration handler.
RootConfigHandler::execute()
Execute this configuration handler.
FilterConfigHandler::execute()
Execute this configuration handler.
ModuleConfigHandler::execute()
Execute this configuration handler.
ValidatorConfigHandler::execute()
Execute this configuration handler.
FactoryConfigHandler::execute()
Execute this configuration handler.
AutoloadConfigHandler::execute()
Execute this configuration handler.
DefineConfigHandler::execute()
Execute this configuration handler.

Parameters:

string   $config   An absolute filesystem path to a configuration file.

[ Top ]

method initialize [line 86]

bool initialize( [array $parameters = null])

Initialize this ConfigHandler.



Tags:

return:  true, if initialization completes successfully, otherwise false.
access:  public
since:  3.0.0
author:  Sean Kerr (skerr@mojavi.org)
throws:  InitializationException If an error occurs while initializing this ConfigHandler.


Parameters:

array   $parameters   An associative array of initialization parameters.

[ Top ]

method literalize [line 110]

string literalize( string $value)

Literalize a string value.



Tags:

return:  A literalized value.
static:  
access:  public
since:  3.0.0
author:  Sean Kerr (skerr@mojavi.org)


Parameters:

string   $value   The value to literalize.

[ Top ]

method replaceConstants [line 167]

string &replaceConstants( string $value)

Replace constant identifiers in a string.



Tags:

return:  The new value.
static:  
access:  public
since:  3.0.0
author:  Sean Kerr (skerr@mojavi.org)


Parameters:

string   $value   The value on which to run the replacement procedure.

[ Top ]

method replacePath [line 195]

string &replacePath( string $path)

Replace a relative filesystem path with an absolute one.



Tags:

return:  The new path.
static:  
access:  public
since:  3.0.0
author:  Sean Kerr (skerr@mojavi.org)


Parameters:

string   $path   A relative filesystem path.

[ Top ]


Documentation generated on Tue, 21 Feb 2006 01:45:11 +0900 by phpDocumentor 1.3.0RC5