class FileResponse implements IResponse

File download response.

Traits

Strict class for better experience.

Properties

bool $resuming

Methods

__construct(string $file, string $name = null, string $contentType = null, bool $forceDownload = true)

No description

string
getFile()

Returns the path to a downloaded file.

string
getName()

Returns the file name.

string
getContentType()

Returns the MIME content type of a downloaded file.

void
send(IRequest $httpRequest, IResponse $httpResponse)

Sends response to output.

Details

at line 38
__construct(string $file, string $name = null, string $contentType = null, bool $forceDownload = true)

Parameters

string $file
string $name
string $contentType
bool $forceDownload

at line 54
string getFile()

Returns the path to a downloaded file.

Return Value

string

at line 63
string getName()

Returns the file name.

Return Value

string

at line 72
string getContentType()

Returns the MIME content type of a downloaded file.

Return Value

string

at line 81
void send(IRequest $httpRequest, IResponse $httpResponse)

Sends response to output.

Parameters

IRequest $httpRequest
IResponse $httpResponse

Return Value

void