API Documentation

Config/Xml.php

Includes Classes 
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Config
version
$Id: Xml.php 20096 2010-01-06 02:05:09Z bkarwin $
Classes
Zend_Config_Xml

Description

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

Zend_Config_Xml

Extends from
Zend_Config
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Config
Constants
XML_NAMESPACE
Properties
$_skipExtends
Methods
__construct
_processExtends
_toArray

Description

XML Adapter for Zend_Config

Constants

XML_NAMESPACE

 XML_NAMESPACE = 'http://framework.zend.com/xml/zend-config-xml/1.0/'

XML namespace for ZF-related tags and attributes

Details

value
http://framework.zend.com/xml/zend-config-xml/1.0/

Properties

$_skipExtends

boolean $_skipExtends = 'false'

Whether to skip extends or not

Details

$_skipExtends
boolean
visibility
protected
default
false
final
false
static
false

Methods

__construct

__construct( string $xml, mixed $section = null, boolean $options = false ) :

Loads the section $section from the config file (or string $xml for access facilitated by nested object properties.

Sections are defined in the XML as children of the root element.

In order to extend another section, a section defines the "extends" attribute having a value of the section name from which the extending section inherits values.

Note that the keys in $section will override any keys of the same name in the sections that have been included via "extends".

Arguments
$xml
string
XML file or string to process
$section
mixed
Section to process
$options
boolean
Whether modifications are allowed at runtime
Details
visibility
public
final
false
static
false
throws
When xml is not set or cannot be loaded
throws
When section $sectionName cannot be found in $xml

_processExtends

_processExtends( SimpleXMLElement $element, string $section, array $config = array ) : array

Helper function to process each element in the section and handle the "extends" inheritance attribute.

Arguments
$element
SimpleXMLElement
XML Element to process
$section
string
Section to process
$config
array
Configuration which was parsed yet
Output
array
Details
visibility
protected
final
false
static
false
throws
When $section cannot be found

_toArray

_toArray( SimpleXMLElement $xmlObject ) : array|string

Returns a string or an associative and possibly multidimensional array from a SimpleXMLElement.

Arguments
$xmlObject
SimpleXMLElement
Convert a SimpleXMLElement into an array
Output
array|string
Details
visibility
protected
final
false
static
false
Documentation was generated by DocBlox.