|
1
|
|
|
<?php |
|
2
|
|
|
|
|
3
|
|
|
declare(strict_types=1); |
|
4
|
|
|
|
|
5
|
|
|
namespace Genkgo\Camt\DTO; |
|
6
|
|
|
|
|
7
|
|
|
use DateTimeImmutable; |
|
8
|
|
|
|
|
9
|
|
|
abstract class Record |
|
10
|
|
|
{ |
|
11
|
|
|
protected string $id; |
|
12
|
|
|
|
|
13
|
|
|
protected DateTimeImmutable $createdOn; |
|
14
|
|
|
|
|
15
|
|
|
protected Account $account; |
|
16
|
|
|
|
|
17
|
|
|
protected ?Pagination $pagination = null; |
|
18
|
|
|
|
|
19
|
|
|
protected ?string $electronicSequenceNumber = null; |
|
20
|
|
|
|
|
21
|
|
|
protected ?string $legalSequenceNumber = null; |
|
22
|
|
|
|
|
23
|
|
|
protected ?string $copyDuplicateIndicator = null; |
|
24
|
|
|
|
|
25
|
|
|
protected ?DateTimeImmutable $fromDate = null; |
|
26
|
|
|
|
|
27
|
|
|
protected ?DateTimeImmutable $toDate = null; |
|
28
|
|
|
|
|
29
|
|
|
/** |
|
30
|
|
|
* @var Entry[] |
|
31
|
|
|
*/ |
|
32
|
|
|
protected $entries = []; |
|
33
|
|
|
|
|
34
|
|
|
protected ?string $additionalInformation = null; |
|
35
|
|
|
|
|
36
|
|
|
public function __construct(string $id, DateTimeImmutable $createdOn, Account $account) |
|
37
|
|
|
{ |
|
38
|
|
|
$this->id = $id; |
|
39
|
|
|
$this->createdOn = $createdOn; |
|
40
|
|
|
$this->account = $account; |
|
41
|
|
|
} |
|
42
|
|
|
|
|
43
|
|
|
public function getId(): string |
|
44
|
|
|
{ |
|
45
|
|
|
return $this->id; |
|
46
|
|
|
} |
|
47
|
|
|
|
|
48
|
|
|
public function getCreatedOn(): DateTimeImmutable |
|
49
|
|
|
{ |
|
50
|
|
|
return $this->createdOn; |
|
51
|
|
|
} |
|
52
|
|
|
|
|
53
|
|
|
public function getAccount(): Account |
|
54
|
|
|
{ |
|
55
|
|
|
return $this->account; |
|
56
|
|
|
} |
|
57
|
|
|
|
|
58
|
|
|
public function getPagination(): ?Pagination |
|
59
|
|
|
{ |
|
60
|
|
|
return $this->pagination; |
|
61
|
|
|
} |
|
62
|
|
|
|
|
63
|
|
|
public function setPagination(Pagination $pagination): void |
|
64
|
|
|
{ |
|
65
|
|
|
$this->pagination = $pagination; |
|
66
|
25 |
|
} |
|
67
|
|
|
|
|
68
|
25 |
|
public function getElectronicSequenceNumber(): ?string |
|
69
|
25 |
|
{ |
|
70
|
25 |
|
return $this->electronicSequenceNumber; |
|
71
|
25 |
|
} |
|
72
|
|
|
|
|
73
|
3 |
|
public function setElectronicSequenceNumber(string $electronicSequenceNumber): void |
|
74
|
|
|
{ |
|
75
|
3 |
|
$this->electronicSequenceNumber = $electronicSequenceNumber; |
|
76
|
|
|
} |
|
77
|
|
|
|
|
78
|
3 |
|
public function getLegalSequenceNumber(): ?string |
|
79
|
|
|
{ |
|
80
|
3 |
|
return $this->legalSequenceNumber; |
|
81
|
|
|
} |
|
82
|
|
|
|
|
83
|
3 |
|
public function setLegalSequenceNumber(string $legalSequenceNumber): void |
|
84
|
|
|
{ |
|
85
|
3 |
|
$this->legalSequenceNumber = $legalSequenceNumber; |
|
86
|
|
|
} |
|
87
|
|
|
|
|
88
|
3 |
|
public function getCopyDuplicateIndicator(): ?string |
|
89
|
|
|
{ |
|
90
|
3 |
|
return $this->copyDuplicateIndicator; |
|
91
|
|
|
} |
|
92
|
|
|
|
|
93
|
13 |
|
public function setCopyDuplicateIndicator(string $copyDuplicateIndicator): void |
|
94
|
|
|
{ |
|
95
|
13 |
|
$this->copyDuplicateIndicator = $copyDuplicateIndicator; |
|
96
|
13 |
|
} |
|
97
|
|
|
|
|
98
|
3 |
|
public function getFromDate(): ?DateTimeImmutable |
|
99
|
|
|
{ |
|
100
|
3 |
|
return $this->fromDate; |
|
101
|
|
|
} |
|
102
|
|
|
|
|
103
|
22 |
|
public function setFromDate(DateTimeImmutable $fromDate): void |
|
104
|
|
|
{ |
|
105
|
22 |
|
$this->fromDate = $fromDate; |
|
106
|
22 |
|
} |
|
107
|
|
|
|
|
108
|
3 |
|
public function getToDate(): ?DateTimeImmutable |
|
109
|
|
|
{ |
|
110
|
3 |
|
return $this->toDate; |
|
111
|
|
|
} |
|
112
|
|
|
|
|
113
|
22 |
|
public function setToDate(DateTimeImmutable $toDate): void |
|
114
|
|
|
{ |
|
115
|
22 |
|
$this->toDate = $toDate; |
|
116
|
22 |
|
} |
|
117
|
|
|
|
|
118
|
3 |
|
public function addEntry(Entry $entry): void |
|
119
|
|
|
{ |
|
120
|
3 |
|
$this->entries[] = $entry; |
|
121
|
|
|
} |
|
122
|
|
|
|
|
123
|
22 |
|
/** |
|
124
|
|
|
* @return Entry[] |
|
125
|
22 |
|
*/ |
|
126
|
22 |
|
public function getEntries(): array |
|
127
|
|
|
{ |
|
128
|
3 |
|
return $this->entries; |
|
129
|
|
|
} |
|
130
|
3 |
|
|
|
131
|
|
|
public function getAdditionalInformation(): ?string |
|
132
|
|
|
{ |
|
133
|
21 |
|
return $this->additionalInformation; |
|
134
|
|
|
} |
|
135
|
21 |
|
|
|
136
|
21 |
|
public function setAdditionalInformation(string $additionalInformation): void |
|
137
|
|
|
{ |
|
138
|
3 |
|
$this->additionalInformation = $additionalInformation; |
|
139
|
|
|
} |
|
140
|
|
|
} |
|
141
|
|
|
|