2
0

Bootstrapper.php 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. <?php
  2. /**
  3. * Zend Framework
  4. *
  5. * LICENSE
  6. *
  7. * This source file is subject to the new BSD license that is bundled
  8. * with this package in the file LICENSE.txt.
  9. * It is also available through the world-wide-web at this URL:
  10. * http://framework.zend.com/license/new-bsd
  11. * If you did not receive a copy of the license and are unable to
  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.
  14. *
  15. * @category Zend
  16. * @package Zend_Application
  17. * @subpackage Bootstrap
  18. * @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
  19. * @license http://framework.zend.com/license/new-bsd New BSD License
  20. * @version $Id$
  21. */
  22. /**
  23. * Interface for bootstrap classes
  24. *
  25. * @category Zend
  26. * @package Zend_Application
  27. * @subpackage Bootstrap
  28. * @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
  29. * @license http://framework.zend.com/license/new-bsd New BSD License
  30. */
  31. interface Zend_Application_Bootstrap_Bootstrapper
  32. {
  33. /**
  34. * Constructor
  35. *
  36. * @param Zend_Application $application
  37. * @return void
  38. */
  39. public function __construct($application);
  40. /**
  41. * Set bootstrap options
  42. *
  43. * @param array $options
  44. * @return Zend_Application_Bootstrap_Bootstrapper
  45. */
  46. public function setOptions(array $options);
  47. /**
  48. * Retrieve application object
  49. *
  50. * @return Zend_Application|Zend_Application_Bootstrap_Bootstrapper
  51. */
  52. public function getApplication();
  53. /**
  54. * Retrieve application environment
  55. *
  56. * @return string
  57. */
  58. public function getEnvironment();
  59. /**
  60. * Retrieve list of class resource initializers (_init* methods). Returns
  61. * as resource/method pairs.
  62. *
  63. * @return array
  64. */
  65. public function getClassResources();
  66. /**
  67. * Retrieve list of class resource initializer names (resource names only,
  68. * no method names)
  69. *
  70. * @return array
  71. */
  72. public function getClassResourceNames();
  73. /**
  74. * Bootstrap application or individual resource
  75. *
  76. * @param null|string $resource
  77. * @return mixed
  78. */
  79. public function bootstrap($resource = null);
  80. /**
  81. * Run the application
  82. *
  83. * @return void
  84. */
  85. public function run();
  86. }