ILIAS  release_7 Revision v7.30-3-g800a261c036
All Data Structures Namespaces Files Functions Variables Modules Pages
StandardNotification.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
21 
23 
30 {
41  private $old_amount = 0;
47  private $new_amount = 1;
48 
50  {
51  $clone = clone $this;
52  $clone->notification_item = $notification_item;
53 
54  return $clone;
55  }
56 
61  {
63  }
64 
68  public function withOldAmount(int $amount = 0) : StandardNotification
69  {
70  $clone = clone $this;
71  $clone->old_amount = $amount;
72 
73  return $clone;
74  }
75 
79  public function withNewAmount(int $amount = 0) : StandardNotification
80  {
81  $clone = clone $this;
82  $clone->new_amount = $amount;
83 
84  return $clone;
85  }
86 
90  public function getOldAmount() : int
91  {
92  return $this->old_amount;
93  }
94 
98  public function getNewAmount() : int
99  {
100  return $this->new_amount;
101  }
102 }
getOldAmount()
Get the amount of new notes, the notification contains.int
Class Notification The default Notification mapping currently to one UI Notification Item component...
Interface hasAmount Items can implicitly contain a various amount of news.
Definition: hasAmount.php:30
getNewAmount()
Get the amount of new notes, the notification contains.int
withOldAmount(int $amount=0)
Set the amount of old notes, the notification contains.StandardNotification
withNewAmount(int $amount=0)
Set the amount of new notes, the notification contains.StandardNotification