Exemplo n.º 1
0
 /**
  * init()
  *
  * @return \Zend\Tool\Project\Context\Zf\TestApplicationControllerFile
  */
 public function init()
 {
     $this->_forControllerName = $this->_resource->getAttribute('forControllerName');
     $this->_filesystemName = ucfirst($this->_forControllerName) . 'ControllerTest.php';
     parent::init();
     return $this;
 }
Exemplo n.º 2
0
 /**
  * init()
  *
  */
 public function init()
 {
     $this->_controllerName = $this->_resource->getAttribute('controllerName');
     $this->_moduleName = $this->_resource->getAttribute('moduleName');
     $this->_filesystemName = ucfirst($this->_controllerName) . 'Controller.php';
     parent::init();
 }
Exemplo n.º 3
0
 /**
  * init()
  *
  * @return \Zend\Tool\Project\Context\Zf\TestLibraryFile
  */
 public function init()
 {
     $this->_forClassName = $this->_resource->getAttribute('forClassName');
     $this->_filesystemName = ucfirst(ltrim(strrchr($this->_forClassName, '_'), '_')) . 'Test.php';
     parent::init();
     return $this;
 }
Exemplo n.º 4
0
 public function init()
 {
     parent::init();
     $this->_applicationConfigFile = $this->_resource->getProfile()->search('ApplicationConfigFile');
     $this->_applicationDirectory = $this->_resource->getProfile()->search('ApplicationDirectory');
     if ($this->_applicationConfigFile === false || $this->_applicationDirectory === false) {
         throw new Exception\RuntimeException('To use the BootstrapFile context, your project requires the use of both the "ApplicationConfigFile" and "ApplicationDirectory" contexts.');
     }
 }
Exemplo n.º 5
0
 /**
  * init()
  *
  * @return \Zend\Tool\Project\Context\Zf\ViewScriptFile
  */
 public function init()
 {
     if ($layoutName = $this->_resource->getAttribute('layoutName')) {
         $this->_layoutName = $layoutName;
     } else {
         throw new Exception\RuntimeException('Either a forActionName or scriptName is required.');
     }
     parent::init();
     return $this;
 }
Exemplo n.º 6
0
 /**
  * init()
  *
  * @return \Zend\Tool\Project\Context\Zf\ProjectProviderFile
  */
 public function init()
 {
     $this->_projectProviderName = $this->_resource->getAttribute('projectProviderName');
     $this->_actionNames = $this->_resource->getAttribute('actionNames');
     $this->_filesystemName = ucfirst($this->_projectProviderName) . 'Provider.php';
     if (strpos($this->_actionNames, ',')) {
         $this->_actionNames = explode(',', $this->_actionNames);
     } else {
         $this->_actionNames = $this->_actionNames ? array($this->_actionNames) : array();
     }
     parent::init();
     return $this;
 }
Exemplo n.º 7
0
 /**
  * init()
  *
  * @return \Zend\Tool\Project\Context\Zf\ViewScriptFile
  */
 public function init()
 {
     if ($forActionName = $this->_resource->getAttribute('forActionName')) {
         $this->_forActionName = $forActionName;
         $this->_filesystemName = $this->_convertActionNameToFilesystemName($forActionName) . '.phtml';
     } elseif ($scriptName = $this->_resource->getAttribute('scriptName')) {
         $this->_scriptName = $scriptName;
         $this->_filesystemName = $scriptName . '.phtml';
     } else {
         throw Zend_Tool_Project_Exception('Either a forActionName or scriptName is required.');
     }
     parent::init();
     return $this;
 }
Exemplo n.º 8
0
 /**
  * save()
  *
  * Proxy to create
  *
  * @return \Zend\Tool\Project\Context\System\ProjectProfileFile
  */
 public function save()
 {
     parent::create();
     return $this;
 }
Exemplo n.º 9
0
 /**
  * init()
  *
  * @return \Zend\Tool\Project\Context\Zf\ApplicationConfigFile
  */
 public function init()
 {
     $this->_type = $this->_resource->getAttribute('type');
     parent::init();
     return $this;
 }