ILIAS  release_7 Revision v7.30-3-g800a261c036
NullRevision.php
Go to the documentation of this file.
1<?php declare(strict_types=1);
2
4
5use DateTimeImmutable;
9
14class NullRevision implements Revision
15{
16
21
27 {
28 $this->identification = $identification;
29 }
30
35 {
37 }
38
42 public function getVersionNumber() : int
43 {
44 return 0;
45 }
46
50 public function getCreationDate() : DateTimeImmutable
51 {
52 return new DateTimeImmutable();
53 }
54
58 public function getInformation() : Information
59 {
60 return new FileInformation();
61 }
62
63 public function setInformation(Information $information)
64 {
65 }
66
67 public function setUnavailable() : void
68 {
69 // do nothing
70 }
71
75 public function isAvailable() : bool
76 {
77 return false;
78 }
79
80 public function getOwnerId() : int
81 {
82 return 0;
83 }
84
85 public function setTitle(string $title) : Revision
86 {
87 // do nothing
88 }
89
90 public function getTitle() : string
91 {
92 return '';
93 }
94
95}
An exception for terminatinating execution or to throw for unit testing.
setInformation(Information $information)
__construct(ResourceIdentification $identification)
NullRevision constructor.