protected json ( mixed $data, integer $status = 200, array $headers = [], array $context = [] ) : Symfony\Component\HttpFoundation\JsonResponse | ||
$data | mixed | The response data |
$status | integer | The status code to use for the Response |
$headers | array | Array of extra headers to add |
$context | array | Context to pass to serializer when using serializer component |
return | Symfony\Component\HttpFoundation\JsonResponse |