/** * ctor * @return void */ public function __construct() { //run baseManager constructor parent::__construct(); //define name of the module $this->module = 'votes'; }
/** * init service current manager * @return void */ public function initCurrentManager() { preg_match_all('/applications\\\\modules\\\\([\\w]*)\\\\services\\\\([\\w]+)Service$/', get_called_class(), $calledClass); $baseManager = new baseManager(); $this->currentManager = $baseManager->getManagerOf($calledClass[1][0] . "\\" . $calledClass[2][0]); }