19 declare(strict_types=1);
52 $this->httpService = $httpState;
61 return is_readable($path_to_file);
71 if ($possible_stream !== null) {
72 $this->file = $possible_stream->detach();
74 $this->file = fopen($path_to_file,
'rb');
83 public function deliver(
string $path_to_file,
bool $file_marked_to_delete): void
85 $this->httpService->sendResponse();
86 fpassthru($this->file);
124 return unlink($path_to_file);
deliver(string $path_to_file, bool $file_marked_to_delete)
absolute path to fileThis is needed at this point for header-based delivery methodsvoid ...
Interface ilFileDeliveryType.
prepare(string $path_to_file, ?FileStream $possible_stream)
__construct(Services $httpState)
PHP constructor.
supportsAttachmentDelivery()
handleFileDeletion(string $path_to_file)
bool
ILIAS HTTP Services $httpService
The base interface for all filesystem streams.
doesFileExists(string $path_to_file)