Completed
Push — feature/EVO-8294-file-upload-r... ( ebbdfa )
by
unknown
63:34
created

ArchiveMetadata::setFilename()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
c 0
b 0
f 0
dl 0
loc 6
rs 9.4285
cc 1
eloc 3
nc 1
nop 1
1
<?php
2
/**
3
 * document class for GravitonDyn\FileBundle\Document\FileMetadata
4
 */
5
6
namespace Graviton\ArchiveBundle\Document;
7
use Doctrine\Common\Collections\ArrayCollection;
8
9
/**
10
 * @author   List of contributors <https://github.com/libgraviton/graviton/graphs/contributors>
11
 * @license  http://opensource.org/licenses/gpl-license.php GNU Public License
12
 * @link     http://swisscom.ch
13
 */
14
class ArchiveMetadata
15
{
16
17
    /**
18
     * @var mixed $id
19
     */
20
    protected $id;
21
22
    /**
23
     * @var \MongoId $id
24
     */
25
    protected $realId;
26
27
    /**
28
     * @var \DateTime $deletedDate
29
     */
30
    protected $deletedDate;
31
32
    /**
33
     * @var string $language
34
     */
35
    protected $language;
36
37
    /**
38
     * @var int $size
39
     */
40
    protected $size;
41
42
    /**
43
     * @var \GravitonDyn\FileBundle\Document\FileMetadataAction[] $action
44
     */
45
    protected $action;
46
47
    /**
48
     * @var string $mime
49
     */
50
    protected $mime;
51
52
    /**
53
     * @var \DateTime $createDate
54
     */
55
    protected $createDate;
56
57
    /**
58
     * @var \DateTime $modificationDate
59
     */
60
    protected $modificationDate;
61
62
    /**
63
     * @var string $filename
64
     */
65
    protected $filename;
66
67
    /**
68
     * @var string $additionalInformation
69
     */
70
    protected $additionalInformation;
71
72
    /**
73
     * @var string $hash
74
     */
75
    protected $hash;
76
77
    /**
78
     * @var ArchiveMetadataAdditionalProperties[] $additionalProperties
79
     */
80
    protected $additionalProperties;
81
82
    /**
83
     * constructor
84
     */
85
    public function __construct()
86
    {
87
        $this->action = new ArrayCollection();
0 ignored issues
show
Documentation Bug introduced by
It seems like new \Doctrine\Common\Collections\ArrayCollection() of type object<Doctrine\Common\C...ctions\ArrayCollection> is incompatible with the declared type array<integer,object<Gra...nt\FileMetadataAction>> of property $action.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
88
        $this->additionalProperties = new ArrayCollection();
0 ignored issues
show
Documentation Bug introduced by
It seems like new \Doctrine\Common\Collections\ArrayCollection() of type object<Doctrine\Common\C...ctions\ArrayCollection> is incompatible with the declared type array<integer,object<Gra...aAdditionalProperties>> of property $additionalProperties.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
89
    }
90
91
    /**
92
     * Get id
93
     *
94
     * @return string $id
95
     */
96
    public function getId()
97
    {
98
        return $this->id;
99
    }
100
101
    /**
102
     * Set id
103
     *
104
     * @param mixed $id id
105
     *
106
     * @return void
107
     */
108
    public function setId($id)
109
    {
110
        $this->id = $id;
111
    }
112
113
    /**
114
     * Get realId
115
     *
116
     * @return string $id
0 ignored issues
show
Documentation introduced by
Should the return type not be \MongoId?

This check compares the return type specified in the @return annotation of a function or method doc comment with the types returned by the function and raises an issue if they mismatch.

Loading history...
117
     */
118
    public function getRealId()
119
    {
120
        return $this->realId;
121
    }
122
123
    /**
124
     * @return \DateTime
125
     */
126
    public function getDeleteddate()
127
    {
128
        return $this->deletedDate;
129
    }
130
131
132
    /**
133
     * Get language
134
     *
135
     * @return string $language
136
     */
137
    public function getLanguage()
138
    {
139
        return $this->language;
140
    }
141
142
    /**
143
     * Set language
144
     *
145
     * @param string $language value for language
146
     *
147
     * @return self
148
     */
149
    public function setLanguage($language)
150
    {
151
        $this->language = $language;
152
153
        return $this;
154
    }
155
156
157
    /**
158
     * Get size
159
     *
160
     * @return int $size
161
     */
162
    public function getSize()
163
    {
164
        return $this->size;
165
    }
166
167
    /**
168
     * Set size
169
     *
170
     * @param int $size value for size
171
     *
172
     * @return self
173
     */
174
    public function setSize($size)
175
    {
176
        $this->size = $size;
177
178
        return $this;
179
    }
180
181
182
    /**
183
     * Get action
184
     *
185
     * @return \GravitonDyn\FileBundle\Document\FileMetadataAction[] $action
186
     */
187
    public function getAction()
188
    {
189
        return $this->action;
190
    }
191
192
    /**
193
     * Set action
194
     *
195
     * @param \GravitonDyn\FileBundle\Document\FileMetadataAction[] $action object for action
196
     *
197
     * @return self
198
     */
199
    public function setAction($action)
200
    {
201
        $this->action = new ArrayCollection($action);
0 ignored issues
show
Documentation Bug introduced by
It seems like new \Doctrine\Common\Col...rrayCollection($action) of type object<Doctrine\Common\C...ctions\ArrayCollection> is incompatible with the declared type array<integer,object<Gra...nt\FileMetadataAction>> of property $action.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
202
203
        return $this;
204
    }
205
206
207
    /**
208
     * add element to action
209
     *
210
     * @param ArchiveMetadataAction $action value to add to action
211
     *
212
     * @return void
213
     */
214
    public function addAction(ArchiveMetadataAction $action)
215
    {
216
        $this->action[] = $action;
217
    }
218
219
    /**
220
     * remove element from action
221
     *
222
     * @param ArchiveMetadataAction $action value to remove from action
223
     *
224
     * @return self
225
     */
226
    public function removeAction(ArchiveMetadataAction $action)
227
    {
228
        $this->action->removeElement($action);
0 ignored issues
show
Bug introduced by
The method removeElement cannot be called on $this->action (of type array<integer,object<Gra...nt\FileMetadataAction>>).

Methods can only be called on objects. This check looks for methods being called on variables that have been inferred to never be objects.

Loading history...
229
230
        return $this;
231
    }
232
233
234
    /**
235
     * Get mime
236
     *
237
     * @return string $mime
238
     */
239
    public function getMime()
240
    {
241
        return $this->mime;
242
    }
243
244
    /**
245
     * Set mime
246
     *
247
     * @param string $mime value for mime
248
     *
249
     * @return self
250
     */
251
    public function setMime($mime)
252
    {
253
        $this->mime = $mime;
254
255
        return $this;
256
    }
257
258
259
    /**
260
     * Get createDate
261
     *
262
     * @return \DateTime $createDate
263
     */
264
    public function getCreatedate()
265
    {
266
        return $this->createDate;
267
    }
268
269
    /**
270
     * Set createDate
271
     *
272
     * @param \DateTime $createDate value for createDate
273
     *
274
     * @return self
275
     */
276
    public function setCreatedate($createDate)
277
    {
278
        $this->createDate = $createDate;
279
280
        return $this;
281
    }
282
283
284
    /**
285
     * Get modificationDate
286
     *
287
     * @return \DateTime $modificationDate
288
     */
289
    public function getModificationdate()
290
    {
291
        return $this->modificationDate;
292
    }
293
294
    /**
295
     * Set modificationDate
296
     *
297
     * @param \DateTime $modificationDate value for modificationDate
298
     *
299
     * @return self
300
     */
301
    public function setModificationdate($modificationDate)
302
    {
303
        $this->modificationDate = $modificationDate;
304
305
        return $this;
306
    }
307
308
309
    /**
310
     * Get filename
311
     *
312
     * @return string $filename
313
     */
314
    public function getFilename()
315
    {
316
        return $this->filename;
317
    }
318
319
    /**
320
     * Set filename
321
     *
322
     * @param string $filename value for filename
323
     *
324
     * @return self
325
     */
326
    public function setFilename($filename)
327
    {
328
        $this->filename = $filename;
329
330
        return $this;
331
    }
332
333
334
    /**
335
     * Get additionalInformation
336
     *
337
     * @return string $additionalInformation
338
     */
339
    public function getAdditionalinformation()
340
    {
341
        return $this->additionalInformation;
342
    }
343
344
    /**
345
     * Set additionalInformation
346
     *
347
     * @param string $additionalInformation value for additionalInformation
348
     *
349
     * @return self
350
     */
351
    public function setAdditionalinformation($additionalInformation)
352
    {
353
        $this->additionalInformation = $additionalInformation;
354
355
        return $this;
356
    }
357
358
359
    /**
360
     * Get hash
361
     *
362
     * @return string $hash
363
     */
364
    public function getHash()
365
    {
366
        return $this->hash;
367
    }
368
369
    /**
370
     * Set hash
371
     *
372
     * @param string $hash value for hash
373
     *
374
     * @return self
375
     */
376
    public function setHash($hash)
377
    {
378
        $this->hash = $hash;
379
380
        return $this;
381
    }
382
383
384
    /**
385
     * Get additionalProperties
386
     *
387
     * @return ArchiveMetadataAdditionalProperties[] $additionalProperties
388
     */
389
    public function getAdditionalproperties()
390
    {
391
        return $this->additionalProperties;
392
    }
393
394
    /**
395
     * Set additionalProperties
396
     *
397
     * @param ArchiveMetadataAdditionalProperties[] $additionalProperties object for additionalProperties
398
     *
399
     * @return self
400
     */
401
    public function setAdditionalproperties($additionalProperties)
402
    {
403
        $this->additionalProperties = new ArrayCollection($additionalProperties);
0 ignored issues
show
Documentation Bug introduced by
It seems like new \Doctrine\Common\Col...($additionalProperties) of type object<Doctrine\Common\C...ctions\ArrayCollection> is incompatible with the declared type array<integer,object<Gra...aAdditionalProperties>> of property $additionalProperties.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
404
405
        return $this;
406
    }
407
408
409
    /**
410
     * add element to additionalProperties
411
     *
412
     * @param ArchiveMetadataAdditionalProperties $additionalProperty value to add to additionalProperties
413
     *
414
     * @return void
415
     */
416
    public function addAdditionalproperty(ArchiveMetadataAdditionalProperties $additionalProperty)
417
    {
418
        $this->additionalProperties[] = $additionalProperty;
419
    }
420
421
    /**
422
     * remove element from additionalProperties
423
     *
424
     * @param ArchiveMetadataAdditionalProperties $additionalProperty value to remove from additionalProperties
425
     *
426
     * @return self
427
     */
428
    public function removeAdditionalproperty(ArchiveMetadataAdditionalProperties $additionalProperty)
429
    {
430
        $this->additionalProperties->removeElement($additionalProperty);
0 ignored issues
show
Bug introduced by
The method removeElement cannot be called on $this->additionalProperties (of type array<integer,object<Gra...aAdditionalProperties>>).

Methods can only be called on objects. This check looks for methods being called on variables that have been inferred to never be objects.

Loading history...
431
432
        return $this;
433
    }
434
435
    /**
436
     * return translatable field names
437
     *
438
     * @return string[]
439
     */
440
    public function getTranslatableFields()
441
    {
442
        return [];
443
    }
444
445
    /**
446
     * return pretranslated field names
447
     *
448
     * @return string[]
449
     */
450
    public function getPreTranslatedFields()
451
    {
452
        return [];
453
    }
454
455
}
456