/** * @param $filename * @return Yamlarh * @throws \Exception */ protected function getNewYamlarh($filename) { $yamlarh = new Yamlarh($filename); $yamlarh->setAccessibleVariable($this->yamlarh->getAccessibleVariable()); $yamlarh->setParamaterKey($this->yamlarh->getParamaterKey()); $yamlarh->setNodes($this->yamlarh->getNodes()); return $yamlarh; }
/** * */ public function __construct($filename = null) { $this->yamlarh = new Yamlarh(null); $this->yamlarh->setParamaterKey(SphringYamlarhConstantEnum::PARAMETERNAME); if (empty($filename)) { $filename = '/' . self::DEFAULT_CONTEXT_FOLDER . '/' . self::DEFAULT_CONTEXT_FILE; } $this->filename = $filename; $this->sphringEventDispatcher = new SphringEventDispatcher($this); $this->extender = new Extender($this->sphringEventDispatcher); $this->factoryBean = new FactoryBean($this); }