Passed
Pull Request — master (#133)
by
unknown
14:52 queued 04:47
created

File::getTitle()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 0
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
namespace EWW\Dpf\Domain\Model;
3
4
/*
5
 * This file is part of the TYPO3 CMS project.
6
 *
7
 * It is free software; you can redistribute it and/or modify it under
8
 * the terms of the GNU General Public License, either version 2
9
 * of the License, or any later version.
10
 *
11
 * For the full copyright and license information, please read the
12
 * LICENSE.txt file that was distributed with this source code.
13
 *
14
 * The TYPO3 project - inspiring people to share!
15
 */
16
17
/**
18
 * File
19
 */
20
class File extends \TYPO3\CMS\Extbase\DomainObject\AbstractEntity
21
{
22
23
    /**
24
     * title
25
     *
26
     * @var string
27
     */
28
    protected $title = '';
29
30
    /**
31
     * label
32
     *
33
     * @var string
34
     */
35
    protected $label = '';
36
37
    /**
38
     * download
39
     *
40
     * @var boolean
41
     */
42
    protected $download;
43
44
    /**
45
     * archive
46
     *
47
     * @var boolean
48
     */
49
    protected $archive;
50
51
    /**
52
     * fileGroupDeleted
53
     *
54
     * @var boolean
55
     */
56
    protected $fileGroupDeleted;
57
58
    /**
59
     * contentType
60
     *
61
     * @var string
62
     */
63
    protected $contentType = '';
64
65
    /**
66
     * link
67
     *
68
     * @var string
69
     */
70
    protected $link = '';
71
72
    /**
73
     * status
74
     *
75
     * @var string
76
     */
77
    protected $status;
78
79
    /**
80
     * primaryFile
81
     *
82
     * @var boolean
83
     */
84
    protected $primaryFile;
85
86
    /**
87
     * datastreamIdentifier
88
     *
89
     * @var string
90
     */
91
    protected $datastreamIdentifier;
92
93
    /**
94
     * document
95
     *
96
     * @var \EWW\Dpf\Domain\Model\Document
97
     */
98
    protected $document = null;
99
100
    const STATUS_REMOTE  = "remote";
101
    const STATUS_DELETED = "deleted";
102
    const STATUS_CHANGED = "changed";
103
    const STATUS_ADDED   = "added";
104
105
    const PRIMARY_DATASTREAM_IDENTIFIER = 'ATT-0';
106
    const DATASTREAM_IDENTIFIER_PREFIX  = 'ATT-';
107
108
    /**
109
     * Returns the title
110
     *
111
     * @return string $title
112
     */
113
    public function getTitle()
114
    {
115
        return $this->title;
116
    }
117
118
    /**
119
     * Sets the title
120
     *
121
     * @param string $title
122
     * @return void
123
     */
124
    public function setTitle($title)
125
    {
126
        $this->title = $title;
127
    }
128
129
    /**
130
     * Returns the label
131
     *
132
     * @return string $label
133
     */
134
    public function getLabel()
135
    {
136
        return $this->label;
137
    }
138
139
    /**
140
     * Sets the label
141
     *
142
     * @param string $label
143
     * @return void
144
     */
145
    public function setLabel($label)
146
    {
147
        $this->label = $label;
148
    }
149
150
    /**
151
     * Returns the download
152
     *
153
     * @return boolean $download
154
     */
155
    public function getDownload()
156
    {
157
        return $this->download;
158
    }
159
160
    /**
161
     * Sets the download
162
     *
163
     * @param string $download
164
     * @return void
165
     */
166
    public function setDownload($download)
167
    {
168
        $this->download = $download;
0 ignored issues
show
Documentation Bug introduced by
The property $download was declared of type boolean, but $download is of type string. Maybe add a type cast?

This check looks for assignments to scalar types that may be of the wrong type.

To ensure the code behaves as expected, it may be a good idea to add an explicit type cast.

$answer = 42;

$correct = false;

$correct = (bool) $answer;
Loading history...
169
    }
170
171
    /**
172
     * Returns the arcive
173
     *
174
     * @return boolean $archive
175
     */
176
    public function getArchive()
177
    {
178
        return $this->archive;
179
    }
180
181
    /**
182
     * Sets the archive
183
     *
184
     * @param boolean $archive
185
     * @return void
186
     */
187
    public function setArchive($archive)
188
    {
189
        $this->archive = $archive;
190
    }
191
192
    /**
193
     * Returns the fileGroupDeleted
194
     *
195
     * @return boolean $fileGroupDeleted
196
     */
197
    public function isFileGroupDeleted()
198
    {
199
        return $this->fileGroupDeleted;
200
    }
201
202
    /**
203
     * Sets the fileGroupDeleted
204
     *
205
     * @return boolean $fileGroupDeleted
206
     */
207
    public function setFileGroupDeleted($fileGroupDeleted)
208
    {
209
        $this->fileGroupDeleted = $fileGroupDeleted;
210
    }
211
212
    /**
213
     * Returns the contentType
214
     *
215
     * @return string $contentType
216
     */
217
    public function getContentType()
218
    {
219
        return $this->contentType;
220
    }
221
222
    /**
223
     * Sets the contentType
224
     *
225
     * @param string $contentType
226
     * @return void
227
     */
228
    public function setContentType($contentType)
229
    {
230
        $this->contentType = $contentType;
231
    }
232
233
    /**
234
     * Returns the link
235
     *
236
     * @return string $link
237
     */
238
    public function getLink()
239
    {
240
        return $this->link;
241
    }
242
243
    /**
244
     * Sets the link
245
     *
246
     * @param string $link
247
     * @return void
248
     */
249
    public function setLink($link)
250
    {
251
        $this->link = $link;
252
    }
253
254
    /**
255
     * Returns the status
256
     *
257
     * @return string $status
258
     */
259
    public function getStatus()
260
    {
261
        return $this->status;
262
    }
263
264
    /**
265
     * Sets the status
266
     *
267
     * @param string $status
268
     * @return void
269
     */
270
    public function setStatus($status)
271
    {
272
        $this->status = $status;
273
    }
274
275
    /**
276
     * Returns the document
277
     *
278
     * @return \EWW\Dpf\Domain\Model\Document $document
279
     */
280
    public function getDocument()
281
    {
282
        return $this->document;
283
    }
284
285
    /**
286
     * Sets the document
287
     *
288
     * @param \EWW\Dpf\Domain\Model\Document $document
289
     * @return void
290
     */
291
    public function setDocument(\EWW\Dpf\Domain\Model\Document $document)
292
    {
293
        $this->document = $document;
294
    }
295
296
    /**
297
     * Returns the primaryFile
298
     *
299
     * @return boolean $primaryFile
300
     */
301
    public function getPrimaryFile()
302
    {
303
        return $this->primaryFile;
304
    }
305
306
    /**
307
     * Sets the primaryFile
308
     *
309
     * @param boolean $primaryFile
310
     * @return void
311
     */
312
    public function setPrimaryFile($primaryFile)
313
    {
314
        $this->primaryFile = $primaryFile;
315
    }
316
317
    /**
318
     * Returns the boolean state of primaryFile
319
     *
320
     * @return boolean
321
     */
322
    public function isPrimaryFile()
323
    {
324
        return $this->primaryFile;
325
    }
326
327
    /**
328
     * Returns the datastreamIdentifier
329
     *
330
     * @return string $datastreamIdentifier
331
     */
332
    public function getDatastreamIdentifier()
333
    {
334
        return $this->datastreamIdentifier;
335
    }
336
337
    /**
338
     * Sets the datastreamIdentifier
339
     *
340
     * @param string $datastreamIdentifier
341
     * @return void
342
     */
343
    public function setDatastreamIdentifier($datastreamIdentifier)
344
    {
345
        $this->datastreamIdentifier = $datastreamIdentifier;
346
    }
347
348
}
349