19declare(strict_types=1);
39 private readonly Closure $link,
40 private readonly Closure $content,
41 private readonly Closure
$txt
47 return UploadHandlerInterface::DEFAULT_FILE_ID_PARAMETER;
52 return $this->
to(
'upload');
57 return $this->
to(
'rm');
62 return $this->
to(
'info');
75 ($this->txt)(
'updated_document'),
78 ))->except(fn() =>
new Ok(
null))->value();
86 private function to(
string $cmd): string
88 return ($this->
link)($cmd);
A result encapsulates a value or an error and simplifies the handling of those.
Class BasicFileInfoResult.
getInfoForExistingFiles(array $file_ids)
getFileIdentifierParameterName()
__construct(private readonly Closure $link, private readonly Closure $content, private readonly Closure $txt)
getInfoResult(string $identifier)
Interface FileInfoResult.
link(string $caption, string $href, bool $new_viewport=false)