ILIAS  trunk Revision v11.0_alpha-1846-g895b5f47236
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
ClonedRevisionInfoResolver.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
20 
22 
26 
33 {
34  protected Information $info;
35 
39  public function __construct(protected int $next_version_number, protected FileRevision $existing_revision)
40  {
41  $this->info = $this->existing_revision->getInformation();
42  }
43 
44  public function getNextVersionNumber(): int
45  {
46  return $this->next_version_number;
47  }
48 
49  public function getOwnerId(): int
50  {
51  return $this->existing_revision->getOwnerId();
52  }
53 
54  public function getRevisionTitle(): string
55  {
56  return $this->existing_revision->getTitle();
57  }
58 
59  public function getFileName(): string
60  {
61  return $this->info->getTitle();
62  }
63 
64  public function getMimeType(): string
65  {
66  return $this->info->getMimeType();
67  }
68 
69  public function getSuffix(): string
70  {
71  return $this->info->getSuffix();
72  }
73 
75  {
76  return new DateTimeImmutable();
77  }
78 
79  public function getSize(): int
80  {
81  return $this->info->getSize();
82  }
83 }
info()
description: > Example for rendering a info message box.
Definition: info.php:34
__construct(protected int $next_version_number, protected FileRevision $existing_revision)
ClonedRevisionInfoResolver constructor.