3declare(strict_types=1);
40 protected \ILIAS\ResourceStorage\Services
$storage;
46 $this->storage =
$DIC->resourceStorage();
55 $result_array = $this->
upload->getResults();
56 $result = end($result_array);
59 if (!$this->is_chunked) {
60 $identifier = $this->storage->manage()->upload($result, $this->stakeholder)->serialize();
61 $status = HandlerResult::STATUS_OK;
65 $status = HandlerResult::STATUS_FAILED;
70 $status = HandlerResult::STATUS_FAILED;
71 $message = $result->getStatus()->getMessage();
79 if (
null !== (
$id = $this->storage->manage()->find($identifier))) {
80 $this->storage->manage()->remove(
$id, $this->stakeholder);
81 $status = HandlerResult::STATUS_OK;
84 $status = HandlerResult::STATUS_OK;
85 $message =
"file with identifier '$identifier' doesn't exist, nothing to do.";
93 if (
null !== (
$id = $this->storage->manage()->find($identifier))) {
94 $revision = $this->storage->manage()->getCurrentRevision(
$id)->getInformation();
95 $title = $revision->getTitle();
97 $mime = $revision->getMimeType();
99 $title = $mime =
'unknown';
109 foreach ($file_ids as $identifier) {
113 return $info_results;
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
Class ilCtrlAwareUploadHandler.
getFileIdentifierParameterName()
@inheritDoc
Class BasicFileInfoResult.
Class BasicHandlerResult.
Class ilCountPDFPagesPreProcessors.
Class ilCtrlAwareStorageUploadHandler.
__construct(ResourceStakeholder $stakeholder)
ILIAS ResourceStorage Services $storage
getInfoResult(string $identifier)
getRemoveResult(string $identifier)
ResourceStakeholder $stakeholder
getInfoForExistingFiles(array $file_ids)
Interface FileInfoResult.
Class ilCtrlAwareUploadHandler.
Interface ResourceStakeholder.
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc