12 * obtain it through the world-wide-web, please send an email |
12 * obtain it through the world-wide-web, please send an email |
13 * to license@zend.com so we can send you a copy immediately. |
13 * to license@zend.com so we can send you a copy immediately. |
14 * |
14 * |
15 * @category Zend |
15 * @category Zend |
16 * @package Zend_Config |
16 * @package Zend_Config |
17 * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) |
17 * @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com) |
18 * @license http://framework.zend.com/license/new-bsd New BSD License |
18 * @license http://framework.zend.com/license/new-bsd New BSD License |
19 * @version $Id: Xml.php 20096 2010-01-06 02:05:09Z bkarwin $ |
19 * @version $Id: Xml.php 24593 2012-01-05 20:35:02Z matthew $ |
20 */ |
20 */ |
21 |
21 |
22 /** |
22 /** |
23 * @see Zend_Config |
23 * @see Zend_Config |
24 */ |
24 */ |
27 /** |
27 /** |
28 * XML Adapter for Zend_Config |
28 * XML Adapter for Zend_Config |
29 * |
29 * |
30 * @category Zend |
30 * @category Zend |
31 * @package Zend_Config |
31 * @package Zend_Config |
32 * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) |
32 * @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com) |
33 * @license http://framework.zend.com/license/new-bsd New BSD License |
33 * @license http://framework.zend.com/license/new-bsd New BSD License |
34 */ |
34 */ |
35 class Zend_Config_Xml extends Zend_Config |
35 class Zend_Config_Xml extends Zend_Config |
36 { |
36 { |
37 /** |
37 /** |
56 * attribute having a value of the section name from which the extending |
56 * attribute having a value of the section name from which the extending |
57 * section inherits values. |
57 * section inherits values. |
58 * |
58 * |
59 * Note that the keys in $section will override any keys of the same |
59 * Note that the keys in $section will override any keys of the same |
60 * name in the sections that have been included via "extends". |
60 * name in the sections that have been included via "extends". |
61 * |
61 * |
62 * @param string $xml XML file or string to process |
62 * The $options parameter may be provided as either a boolean or an array. |
63 * @param mixed $section Section to process |
63 * If provided as a boolean, this sets the $allowModifications option of |
64 * @param boolean $options Whether modifications are allowed at runtime |
64 * Zend_Config. If provided as an array, there are two configuration |
|
65 * directives that may be set. For example: |
|
66 * |
|
67 * $options = array( |
|
68 * 'allowModifications' => false, |
|
69 * 'skipExtends' => false |
|
70 * ); |
|
71 * |
|
72 * @param string $xml XML file or string to process |
|
73 * @param mixed $section Section to process |
|
74 * @param array|boolean $options |
65 * @throws Zend_Config_Exception When xml is not set or cannot be loaded |
75 * @throws Zend_Config_Exception When xml is not set or cannot be loaded |
66 * @throws Zend_Config_Exception When section $sectionName cannot be found in $xml |
76 * @throws Zend_Config_Exception When section $sectionName cannot be found in $xml |
67 */ |
77 */ |
68 public function __construct($xml, $section = null, $options = false) |
78 public function __construct($xml, $section = null, $options = false) |
69 { |
79 { |