예제 #1
0
파일: Json.php 프로젝트: bullhorn/fast-rest
 /**
  * This takes in object, and outputs it in the respective format, including sending the headers
  *
  * @param \stdClass $object
  * @param ResponseInterface $response
  *
  * @return void
  */
 public function output(\stdClass $object, ResponseInterface $response)
 {
     $response->setContentType('application/json');
     $response->setJsonContent($object);
     $response->send();
 }