public function sendFile($file, $status = 200, array $headers = [], $contentDisposition = null)
    {
        return new BinaryFileResponse($file, $status, $headers, true, $contentDisposition);
    }
public function sendFile($file, $status = 200, array $headers = [], $contentDisposition = null)
    {
        return new BinaryFileResponse($file, $status, $headers, true, $contentDisposition);
    }
public function sendFile ( $ file , $ status = 200 , array $ headers = [ ] , $ contentDisposition = null ) { return new BinaryFileResponse ( $ file , $ status , $ headers , true , $ contentDisposition ) ; }
Sends a file.

@param \SplFileInfo|string $file               The file to stream
@param int                 $status             The response status code
@param array               $headers            An array of response headers
@param null|string         $contentDisposition The type of Content-Disposition to set automatically with the filename

@return BinaryFileResponse
Sends a file .