Application.php
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.
- Category
- Zend
- Copyright
- Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)
- License
- New BSD License
- Package
- Zend_Application
- Version
- $Id$
\Zend_Application
Package: Zend_Application
Throws












- Category
- Zend
- Copyright
- Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)
- License
- New BSD License
Properties
Methods

__construct(string $environment, string | array | \Zend_Config $options = null) : voidConstructor
Initialize application. Potentially initializes include_paths, PHP
settings, and bootstrap class.
Parameters| Name | Type | Description |
|---|---|---|
| $environment | string | |
| $options | string | array | \Zend_Config | String path to configuration file, or array/Zend_Config of configuration options |
| Exception | Description |
|---|---|
| \Zend_Application_Exception | When invalid options are provided |

_loadConfig(string $file) : arrayLoad configuration file of options
Parameters
Returns
Throws
| Name | Type | Description |
|---|---|---|
| $file | string |
| Type | Description |
|---|---|
| array |
| Exception | Description |
|---|---|
| \Zend_Application_Exception | When invalid configuration file is provided |

bootstrap(null | string | array $resource = null) : \Zend_ApplicationBootstrap application
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $resource | null | string | array |
| Type | Description |
|---|---|
| \Zend_Application |

getAutoloader() : \Zend_Loader_AutoloaderRetrieve autoloader instance
Returns
| Type | Description |
|---|---|
| \Zend_Loader_Autoloader |

getBootstrap() : \Zend_Application_Bootstrap_BootstrapAbstractGet bootstrap object
Returns
| Type | Description |
|---|---|
| \Zend_Application_Bootstrap_BootstrapAbstract |

getOption(string $key) : mixedRetrieve a single option
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $key | string |
| Type | Description |
|---|---|
| mixed |

hasOption(string $key) : boolIs an option present?
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $key | string |
| Type | Description |
|---|---|
| bool |

mergeOptions(array $array1, mixed $array2 = null) : arrayMerge options recursively
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $array1 | array | |
| $array2 | mixed |
| Type | Description |
|---|---|
| array |

setAutoloaderNamespaces(array $namespaces) : \Zend_ApplicationSet autoloader namespaces
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $namespaces | array |
| Type | Description |
|---|---|
| \Zend_Application |

setBootstrap(string $path, string $class = null) : \Zend_ApplicationSet bootstrap path/class
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $path | string | |
| $class | string |
| Type | Description |
|---|---|
| \Zend_Application |

setIncludePaths(array $paths) : \Zend_ApplicationSet include path
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $paths | array |
| Type | Description |
|---|---|
| \Zend_Application |

setOptions(array $options) : \Zend_ApplicationSet application options
Parameters
Returns
Throws
| Name | Type | Description |
|---|---|---|
| $options | array |
| Type | Description |
|---|---|
| \Zend_Application |
| Exception | Description |
|---|---|
| \Zend_Application_Exception | When no bootstrap path is provided |
| \Zend_Application_Exception | When invalid bootstrap information are provided |

setPhpSettings(array $settings, string $prefix = '') : \Zend_ApplicationSet PHP configuration settings
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $settings | array | |
| $prefix | string | Key prefix to prepend to array values (used to map . separated INI values) |
| Type | Description |
|---|---|
| \Zend_Application |