private function _initErrorReporting() { Zend_SetupInit::initErrorReporting(); // set the test environment parameters if (('local' | 'development') === Zend_SetupInit::$_env) { $this->_front->throwExceptions(true); } }
function __construct($user = null) { if (null === $user) { throw new Zend_Exception('Username must be passed!'); } Zend_SetupInit::setupInit(); $this->_config = Zend_Registry::get(Zend_SetupInit::$_env); $this->_user = $user; }
function __construct() { try { Zend_SetupInit::setupInit(); $this->_config = Zend_Registry::get(Zend_SetupInit::$_env); $user = $this->_config->twitter->user; $pass = $this->_config->twitter->pass; $this->_twitter = new Zend_Service_Twitter($user, $pass); $this->_response = $this->_twitter->account->verifyCredentials(); if ($this->_response->error()) { throw new Zend_Exception('An error occurred.'); } } catch (Exception $e) { // @todo please catch me. } }
/** * Initialize environment * * @access public * @return void * */ protected static function _setEnv() { self::$_env = self::$_general->environment; }