1 | <?php |
||
16 | class Quarantine |
||
17 | { |
||
18 | |||
19 | 1 | public static function fromList(array $values) |
|
29 | |||
30 | 2 | public static function fromValue(\stdClass $value) |
|
34 | |||
35 | /** |
||
36 | * @var \stdClass |
||
37 | */ |
||
38 | protected $source; |
||
39 | |||
40 | /** |
||
41 | * @var QuarantineSession |
||
42 | */ |
||
43 | protected $session; |
||
44 | |||
45 | /** |
||
46 | * @var string[]|ArrayCollection |
||
47 | */ |
||
48 | protected $checks; |
||
49 | |||
50 | /** |
||
51 | * @var \DateTime |
||
52 | */ |
||
53 | protected $createdOn; |
||
54 | |||
55 | /** |
||
56 | * @var \DateTime |
||
57 | */ |
||
58 | protected $updatedOn; |
||
59 | |||
60 | /** |
||
61 | * @param \stdClass $source |
||
62 | */ |
||
63 | 2 | public function __construct(\stdClass $source) |
|
67 | |||
68 | /** |
||
69 | * @return \stdClass |
||
70 | */ |
||
71 | public function getRawData() |
||
75 | 2 | ||
76 | /** |
||
77 | * Get Quarantine item id |
||
78 | * |
||
79 | * @return integer |
||
80 | */ |
||
81 | public function getId() |
||
85 | 2 | ||
86 | /** |
||
87 | * Get The related quarantine session |
||
88 | * |
||
89 | * @return QuarantineSession |
||
90 | */ |
||
91 | public function getSession() |
||
95 | 2 | ||
96 | /** |
||
97 | * Get the related base id |
||
98 | * |
||
99 | * @return integer |
||
100 | */ |
||
101 | public function getBaseId() |
||
105 | 2 | ||
106 | /** |
||
107 | * Get the item original name |
||
108 | * |
||
109 | * @return string |
||
110 | */ |
||
111 | public function getOriginalName() |
||
115 | 2 | ||
116 | /** |
||
117 | * Get the item SHA 256 HASH |
||
118 | * |
||
119 | * @return string |
||
120 | */ |
||
121 | public function getSha256() |
||
125 | 2 | ||
126 | /** |
||
127 | * Get the item UUID |
||
128 | * |
||
129 | * @return string |
||
130 | */ |
||
131 | public function getUuid() |
||
135 | 2 | ||
136 | /** |
||
137 | * Tell whether the item has been forced to the quarantine |
||
138 | * |
||
139 | * @return Boolean |
||
140 | */ |
||
141 | public function isForced() |
||
145 | 2 | ||
146 | /** |
||
147 | * Get the check messages as a collection of string |
||
148 | * |
||
149 | * @return string[] |
||
150 | */ |
||
151 | public function getChecks() |
||
155 | 2 | ||
156 | /** |
||
157 | * Creation date |
||
158 | * |
||
159 | * @return \DateTime |
||
160 | */ |
||
161 | public function getCreatedOn() |
||
165 | 2 | ||
166 | /** |
||
167 | * Last updated date |
||
168 | * |
||
169 | * @return \DateTime |
||
170 | */ |
||
171 | public function getUpdatedOn() |
||
175 | } |
||
176 |