/** * @param \Classes\Db\DbTable|\Classes\Db\Constrant $table * * @return mixed */ public function createClassNamespace($table) { $arrNames = $this->getBaseNamespace(); if (isset($this->arrConfig['folder-database']) && $this->arrConfig['folder-database']) { $arrNames[] = AbstractMaker::getClassName($this->arrConfig['driver']); } if (isset($this->arrConfig['folder-name']) && $this->arrConfig['folder-name']) { $arrNames[] = AbstractMaker::getClassName($this->arrConfig['folder-name']); } if ($table->hasSchema()) { $arrNames[] = $this->replaceReservedWord(AbstractMaker::getClassName($table->getSchema())); } else { $arrNames[] = $this->replaceReservedWord(AbstractMaker::getClassName($table->getDatabase())); } return implode(static::SEPARETOR, array_filter($arrNames)); }