예제 #1
0
	public function Begin() {
	
		$url = $_GET;

		/** 
		 * pseudocode: 
		 * $url = split($_GET, '/');
		 * $controllerName = $url[0];
		 * $actionName = $url[1];
		 * $queryParams = $url[2...];
		 **/
		
		$controllerFactory = new ControllerFactory();
		$controller = $controllerFactory->CreateController($controllerName, $actionName);
		
		$controller->OnActionExecuting();
		$controller->ExecuteAction($queryParams);
		$controller->OnActionExecuted();
	}