public function putAction(Application $app, Request $request, \RREST\Response $response, $slotId = null) { return $response->getRouterResponse(); }
public function getAction(Application $app, Request $request, Response $response) { return $response->getRouterResponse(); }
/** * @param RouterInterface $router * @param string $statusCodeSucess * @param string $format * @param string $mimeType * * @return Response */ protected function getResponse(RouterInterface $router, $statusCodeSucess, $format, $mimeType) { if ($format === false) { throw new \RuntimeException('Can\'t find a supported format for this Accept header. RRest only support json & xml.'); } $response = new Response($router, $format, $statusCodeSucess); $response->setContentType($mimeType); return $response; }