/** * Let the FluxBB server execute the given action and return its response data. * * @param string $action * @param array $parameters * @return array */ public function dispatch($action, array $parameters = []) { return $this->server->dispatch(new Request($action, $parameters))->getData(); }
/** * Resolve the request and return a response. * * @param \FluxBB\Server\Request $request * @return \FluxBB\Server\Response * @throws \FluxBB\Server\Exception\Exception */ public function dispatch(Request $request) { $this->validate($request); return $this->next->dispatch($request); }
/** * Let the FluxBB server execute the given action and return its response data. * * @param string $action * @param array $parameters * @return array */ protected function execute($action, array $parameters = []) { $parameters += $this->input; return $this->server->dispatch(new ServerRequest($action, $parameters))->getData(); }
/** * Resolve the request and return a response. * * @param \FluxBB\Server\Request $request * @return \FluxBB\Server\Response * @throws \FluxBB\Server\Exception\Exception */ public function dispatch(Request $request) { $this->authorize($request); return $this->next->dispatch($request); }