1
|
|
|
<?php |
2
|
|
|
|
3
|
|
|
/* |
4
|
|
|
* This file is part of the zibios/wrike-php-jmsserializer package. |
5
|
|
|
* |
6
|
|
|
* (c) Zbigniew Ślązak |
7
|
|
|
* |
8
|
|
|
* For the full copyright and license information, please view the LICENSE |
9
|
|
|
* file that was distributed with this source code. |
10
|
|
|
*/ |
11
|
|
|
|
12
|
|
|
namespace Zibios\WrikePhpJmsserializer\Model\Comment; |
13
|
|
|
|
14
|
|
|
use JMS\Serializer\Annotation as SA; |
15
|
|
|
use Zibios\WrikePhpJmsserializer\Model\AbstractModel; |
16
|
|
|
use Zibios\WrikePhpJmsserializer\Model\ResourceModelInterface; |
17
|
|
|
|
18
|
|
|
/** |
19
|
|
|
* Comment Resource Model. |
20
|
|
|
*/ |
21
|
|
|
class CommentResourceModel extends AbstractModel implements ResourceModelInterface |
22
|
|
|
{ |
23
|
|
|
/** |
24
|
|
|
* Comment ID. |
25
|
|
|
* |
26
|
|
|
* Comment: Comment ID |
27
|
|
|
* |
28
|
|
|
* @SA\Type("string") |
29
|
|
|
* @SA\SerializedName("id") |
30
|
|
|
* |
31
|
|
|
* @var string|null |
32
|
|
|
*/ |
33
|
|
|
protected $id; |
34
|
|
|
|
35
|
|
|
/** |
36
|
|
|
* Author ID. |
37
|
|
|
* |
38
|
|
|
* Comment: Contact ID |
39
|
|
|
* |
40
|
|
|
* @SA\Type("string") |
41
|
|
|
* @SA\SerializedName("authorId") |
42
|
|
|
* |
43
|
|
|
* @var string|null |
44
|
|
|
*/ |
45
|
|
|
protected $authorId; |
46
|
|
|
|
47
|
|
|
/** |
48
|
|
|
* Comment text. |
49
|
|
|
* |
50
|
|
|
* @SA\Type("string") |
51
|
|
|
* @SA\SerializedName("text") |
52
|
|
|
* |
53
|
|
|
* @var string|null |
54
|
|
|
*/ |
55
|
|
|
protected $text; |
56
|
|
|
|
57
|
|
|
/** |
58
|
|
|
* Created date. |
59
|
|
|
* |
60
|
|
|
* Format: yyyy-MM-dd'T'HH:mm:ss'Z' |
61
|
|
|
* |
62
|
|
|
* @SA\Type("string") |
63
|
|
|
* @SA\SerializedName("createdDate") |
64
|
|
|
* |
65
|
|
|
* @var string|null |
66
|
|
|
*/ |
67
|
|
|
protected $createdDate; |
68
|
|
|
|
69
|
|
|
/** |
70
|
|
|
* Updated date. |
71
|
|
|
* |
72
|
|
|
* Format: yyyy-MM-dd'T'HH:mm:ss'Z' |
73
|
|
|
* |
74
|
|
|
* @SA\Type("string") |
75
|
|
|
* @SA\SerializedName("updatedDate") |
76
|
|
|
* |
77
|
|
|
* @var string|null |
78
|
|
|
*/ |
79
|
|
|
protected $updatedDate; |
80
|
|
|
|
81
|
|
|
/** |
82
|
|
|
* ID of related task. Only one of taskId/folderId fields is present. |
83
|
|
|
* |
84
|
|
|
* @SA\Type("string") |
85
|
|
|
* @SA\SerializedName("taskId") |
86
|
|
|
* |
87
|
|
|
* @var string|null |
88
|
|
|
*/ |
89
|
|
|
protected $taskId; |
90
|
|
|
|
91
|
|
|
/** |
92
|
|
|
* ID of related folder. Only one of taskId/folderId fields is present. |
93
|
|
|
* |
94
|
|
|
* @SA\Type("string") |
95
|
|
|
* @SA\SerializedName("folderId") |
96
|
|
|
* |
97
|
|
|
* @var string|null |
98
|
|
|
*/ |
99
|
|
|
protected $folderId; |
100
|
|
|
|
101
|
|
|
/** |
102
|
|
|
* @return null|string |
103
|
|
|
*/ |
104
|
1 |
|
public function getId() |
105
|
|
|
{ |
106
|
1 |
|
return $this->id; |
107
|
|
|
} |
108
|
|
|
|
109
|
|
|
/** |
110
|
|
|
* @param null|string $id |
111
|
|
|
* |
112
|
|
|
* @return $this |
113
|
|
|
*/ |
114
|
1 |
|
public function setId($id) |
115
|
|
|
{ |
116
|
1 |
|
$this->id = $id; |
117
|
|
|
|
118
|
1 |
|
return $this; |
119
|
|
|
} |
120
|
|
|
|
121
|
|
|
/** |
122
|
|
|
* @return null|string |
123
|
|
|
*/ |
124
|
1 |
|
public function getAuthorId() |
125
|
|
|
{ |
126
|
1 |
|
return $this->authorId; |
127
|
|
|
} |
128
|
|
|
|
129
|
|
|
/** |
130
|
|
|
* @param null|string $authorId |
131
|
|
|
* |
132
|
|
|
* @return $this |
133
|
|
|
*/ |
134
|
1 |
|
public function setAuthorId($authorId) |
135
|
|
|
{ |
136
|
1 |
|
$this->authorId = $authorId; |
137
|
|
|
|
138
|
1 |
|
return $this; |
139
|
|
|
} |
140
|
|
|
|
141
|
|
|
/** |
142
|
|
|
* @return null|string |
143
|
|
|
*/ |
144
|
1 |
|
public function getText() |
145
|
|
|
{ |
146
|
1 |
|
return $this->text; |
147
|
|
|
} |
148
|
|
|
|
149
|
|
|
/** |
150
|
|
|
* @param null|string $text |
151
|
|
|
* |
152
|
|
|
* @return $this |
153
|
|
|
*/ |
154
|
1 |
|
public function setText($text) |
155
|
|
|
{ |
156
|
1 |
|
$this->text = $text; |
157
|
|
|
|
158
|
1 |
|
return $this; |
159
|
|
|
} |
160
|
|
|
|
161
|
|
|
/** |
162
|
|
|
* @return string|null |
163
|
|
|
*/ |
164
|
1 |
|
public function getCreatedDate() |
165
|
|
|
{ |
166
|
1 |
|
return $this->createdDate; |
167
|
|
|
} |
168
|
|
|
|
169
|
|
|
/** |
170
|
|
|
* @param string|null $createdDate |
171
|
|
|
* |
172
|
|
|
* @return $this |
173
|
|
|
*/ |
174
|
1 |
|
public function setCreatedDate($createdDate) |
175
|
|
|
{ |
176
|
1 |
|
$this->createdDate = $createdDate; |
177
|
|
|
|
178
|
1 |
|
return $this; |
179
|
|
|
} |
180
|
|
|
|
181
|
|
|
/** |
182
|
|
|
* @return null|string |
183
|
|
|
*/ |
184
|
1 |
|
public function getUpdatedDate() |
185
|
|
|
{ |
186
|
1 |
|
return $this->updatedDate; |
187
|
|
|
} |
188
|
|
|
|
189
|
|
|
/** |
190
|
|
|
* @param null|string $updatedDate |
191
|
|
|
* |
192
|
|
|
* @return $this |
193
|
|
|
*/ |
194
|
1 |
|
public function setUpdatedDate($updatedDate) |
195
|
|
|
{ |
196
|
1 |
|
$this->updatedDate = $updatedDate; |
197
|
|
|
|
198
|
1 |
|
return $this; |
199
|
|
|
} |
200
|
|
|
|
201
|
|
|
/** |
202
|
|
|
* @return null|string |
203
|
|
|
*/ |
204
|
1 |
|
public function getTaskId() |
205
|
|
|
{ |
206
|
1 |
|
return $this->taskId; |
207
|
|
|
} |
208
|
|
|
|
209
|
|
|
/** |
210
|
|
|
* @param null|string $taskId |
211
|
|
|
* |
212
|
|
|
* @return $this |
213
|
|
|
*/ |
214
|
1 |
|
public function setTaskId($taskId) |
215
|
|
|
{ |
216
|
1 |
|
$this->taskId = $taskId; |
217
|
|
|
|
218
|
1 |
|
return $this; |
219
|
|
|
} |
220
|
|
|
|
221
|
|
|
/** |
222
|
|
|
* @return null|string |
223
|
|
|
*/ |
224
|
1 |
|
public function getFolderId() |
225
|
|
|
{ |
226
|
1 |
|
return $this->folderId; |
227
|
|
|
} |
228
|
|
|
|
229
|
|
|
/** |
230
|
|
|
* @param null|string $folderId |
231
|
|
|
* |
232
|
|
|
* @return $this |
233
|
|
|
*/ |
234
|
1 |
|
public function setFolderId($folderId) |
235
|
|
|
{ |
236
|
1 |
|
$this->folderId = $folderId; |
237
|
|
|
|
238
|
1 |
|
return $this; |
239
|
|
|
} |
240
|
|
|
} |
241
|
|
|
|