Example #1
0
 /**
  * @return string
  */
 public function classNameTo_URI($className)
 {
     if (AbstractService::isSubclass($className)) {
         return $this->toService_URI($className);
     } else {
         if (MVC\Controller\Action\AbstractAction::isSubclass($className)) {
             return $this->toAction_URI($className);
         } else {
             if (MVC\Controller\AbstractController::isSubclass($className)) {
                 return $this->toController_URI($className);
             } else {
                 if (MVC\Controller\AbstractFrontController::isSubclass($className)) {
                     return $this->toFrontController_URI($className);
                 } else {
                     return null;
                 }
             }
         }
     }
 }
Example #2
0
 /**
  * @return void
  */
 protected function exportMetaClasses()
 {
     $this->scanPhpDefinitions('src/Service', function ($className) {
         if (AbstractContractor::isSubclass($className)) {
             $this->metadriver->addMetaService($className, $this->getPackage());
         }
     });
     $this->scanPhpDefinitions('src/Action', function ($className) {
         if (MVC\Controller\Action\AbstractAction::isSubclass($className)) {
             $this->metadriver->addMetaAction($className, $this->getPackage());
         }
     });
     $this->scanPhpDefinitions('src/Controller', function ($className) {
         if (MVC\Controller\AbstractController::isSubclass($className)) {
             $this->metadriver->addMetaController($className, $this->getPackage());
         }
     });
     $this->scanPhpDefinitions('src/FrontController', function ($className) {
         if (MVC\Controller\AbstractFrontController::isSubclass($className)) {
             $this->metadriver->addMetaFrontController($className, $this->getPackage());
         }
     });
 }