/** * Creates a new Response entity. * * @param FacebookBatchRequest $batchRequest * @param FacebookResponse $response */ public function __construct(FacebookBatchRequest $batchRequest, FacebookResponse $response) { $this->batchRequest = $batchRequest; $request = $response->getRequest(); $body = $response->getBody(); $httpStatusCode = $response->getHttpStatusCode(); $headers = $response->getHeaders(); parent::__construct($request, $body, $httpStatusCode, $headers); $responses = $response->getDecodedBody(); $this->setResponses($responses); }