1
|
|
|
<?php |
2
|
|
|
/** |
3
|
|
|
* BigBlueButton open source conferencing system - http://www.bigbluebutton.org/. |
4
|
|
|
* |
5
|
|
|
* Copyright (c) 2016 BigBlueButton Inc. and by respective authors (see below). |
6
|
|
|
* |
7
|
|
|
* This program is free software; you can redistribute it and/or modify it under the |
8
|
|
|
* terms of the GNU Lesser General Public License as published by the Free Software |
9
|
|
|
* Foundation; either version 3.0 of the License, or (at your option) any later |
10
|
|
|
* version. |
11
|
|
|
* |
12
|
|
|
* BigBlueButton is distributed in the hope that it will be useful, but WITHOUT ANY |
13
|
|
|
* WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A |
14
|
|
|
* PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. |
15
|
|
|
* |
16
|
|
|
* You should have received a copy of the GNU Lesser General Public License along |
17
|
|
|
* with BigBlueButton; if not, see <http://www.gnu.org/licenses/>. |
18
|
|
|
*/ |
19
|
|
|
namespace BigBlueButton\Parameters; |
20
|
|
|
|
21
|
|
|
/** |
22
|
|
|
* Class JoinMeetingParametersTest. |
23
|
|
|
*/ |
24
|
|
|
class JoinMeetingParameters extends BaseParameters |
25
|
|
|
{ |
26
|
|
|
/** |
27
|
|
|
* @var string |
28
|
|
|
*/ |
29
|
|
|
private $meetingId; |
30
|
|
|
|
31
|
|
|
/** |
32
|
|
|
* @var string |
33
|
|
|
*/ |
34
|
|
|
private $username; |
35
|
|
|
|
36
|
|
|
/** |
37
|
|
|
* @var string |
38
|
|
|
*/ |
39
|
|
|
private $password; |
40
|
|
|
|
41
|
|
|
/** |
42
|
|
|
* @var string |
43
|
|
|
*/ |
44
|
|
|
private $userId; |
45
|
|
|
|
46
|
|
|
/** |
47
|
|
|
* @var string |
48
|
|
|
*/ |
49
|
|
|
private $webVoiceConf; |
50
|
|
|
|
51
|
|
|
/** |
52
|
|
|
* @var string |
53
|
|
|
*/ |
54
|
|
|
private $creationTime; |
55
|
|
|
|
56
|
|
|
/** |
57
|
|
|
* @var string |
58
|
|
|
*/ |
59
|
|
|
private $configToken; |
60
|
|
|
|
61
|
|
|
/** |
62
|
|
|
* @var string |
63
|
|
|
*/ |
64
|
|
|
private $avatarURL; |
65
|
|
|
|
66
|
|
|
/** |
67
|
|
|
* @var boolean |
68
|
|
|
*/ |
69
|
|
|
private $redirect; |
70
|
|
|
|
71
|
|
|
/** |
72
|
|
|
* @var |
73
|
|
|
*/ |
74
|
|
|
private $clientURL; |
75
|
|
|
|
76
|
|
|
/** |
77
|
|
|
* JoinMeetingParametersTest constructor. |
78
|
|
|
* |
79
|
|
|
* @param $meetingId |
80
|
|
|
* @param $username |
81
|
|
|
* @param $password |
82
|
|
|
*/ |
83
|
|
|
public function __construct($meetingId, $username, $password) |
84
|
|
|
{ |
85
|
|
|
$this->meetingId = $meetingId; |
86
|
|
|
$this->username = $username; |
87
|
|
|
$this->password = $password; |
88
|
|
|
} |
89
|
|
|
|
90
|
|
|
/** |
91
|
|
|
* @return string |
92
|
|
|
*/ |
93
|
|
|
public function getMeetingId() |
94
|
|
|
{ |
95
|
|
|
return $this->meetingId; |
96
|
|
|
} |
97
|
|
|
|
98
|
|
|
/** |
99
|
|
|
* @param string $meetingId |
100
|
|
|
* |
101
|
|
|
* @return JoinMeetingParameters |
102
|
|
|
*/ |
103
|
|
|
public function setMeetingId($meetingId) |
104
|
|
|
{ |
105
|
|
|
$this->meetingId = $meetingId; |
106
|
|
|
|
107
|
|
|
return $this; |
108
|
|
|
} |
109
|
|
|
|
110
|
|
|
/** |
111
|
|
|
* @return string |
112
|
|
|
*/ |
113
|
|
|
public function getUsername() |
114
|
|
|
{ |
115
|
|
|
return $this->username; |
116
|
|
|
} |
117
|
|
|
|
118
|
|
|
/** |
119
|
|
|
* @param string $username |
120
|
|
|
* |
121
|
|
|
* @return JoinMeetingParameters |
122
|
|
|
*/ |
123
|
|
|
public function setUsername($username) |
124
|
|
|
{ |
125
|
|
|
$this->username = $username; |
126
|
|
|
|
127
|
|
|
return $this; |
128
|
|
|
} |
129
|
|
|
|
130
|
|
|
/** |
131
|
|
|
* @return string |
132
|
|
|
*/ |
133
|
|
|
public function getPassword() |
134
|
|
|
{ |
135
|
|
|
return $this->password; |
136
|
|
|
} |
137
|
|
|
|
138
|
|
|
/** |
139
|
|
|
* @param string $password |
140
|
|
|
* |
141
|
|
|
* @return JoinMeetingParameters |
142
|
|
|
*/ |
143
|
|
|
public function setPassword($password) |
144
|
|
|
{ |
145
|
|
|
$this->password = $password; |
146
|
|
|
|
147
|
|
|
return $this; |
148
|
|
|
} |
149
|
|
|
|
150
|
|
|
/** |
151
|
|
|
* @return string |
152
|
|
|
*/ |
153
|
|
|
public function getUserId() |
154
|
|
|
{ |
155
|
|
|
return $this->userId; |
156
|
|
|
} |
157
|
|
|
|
158
|
|
|
/** |
159
|
|
|
* @param string $userId |
160
|
|
|
* |
161
|
|
|
* @return JoinMeetingParameters |
162
|
|
|
*/ |
163
|
|
|
public function setUserId($userId) |
164
|
|
|
{ |
165
|
|
|
$this->userId = $userId; |
166
|
|
|
|
167
|
|
|
return $this; |
168
|
|
|
} |
169
|
|
|
|
170
|
|
|
/** |
171
|
|
|
* @return string |
172
|
|
|
*/ |
173
|
|
|
public function getWebVoiceConf() |
174
|
|
|
{ |
175
|
|
|
return $this->webVoiceConf; |
176
|
|
|
} |
177
|
|
|
|
178
|
|
|
/** |
179
|
|
|
* @param string $webVoiceConf |
180
|
|
|
* |
181
|
|
|
* @return JoinMeetingParameters |
182
|
|
|
*/ |
183
|
|
|
public function setWebVoiceConf($webVoiceConf) |
184
|
|
|
{ |
185
|
|
|
$this->webVoiceConf = $webVoiceConf; |
186
|
|
|
|
187
|
|
|
return $this; |
188
|
|
|
} |
189
|
|
|
|
190
|
|
|
/** |
191
|
|
|
* @return int |
192
|
|
|
*/ |
193
|
|
|
public function getCreationTime() |
194
|
|
|
{ |
195
|
|
|
return $this->creationTime; |
196
|
|
|
} |
197
|
|
|
|
198
|
|
|
/** |
199
|
|
|
* @param int $creationTime |
200
|
|
|
* |
201
|
|
|
* @return JoinMeetingParameters |
202
|
|
|
*/ |
203
|
|
|
public function setCreationTime($creationTime) |
204
|
|
|
{ |
205
|
|
|
$this->creationTime = $creationTime; |
|
|
|
|
206
|
|
|
|
207
|
|
|
return $this; |
208
|
|
|
} |
209
|
|
|
|
210
|
|
|
/** |
211
|
|
|
* @return string |
212
|
|
|
*/ |
213
|
|
|
public function getConfigToken() |
214
|
|
|
{ |
215
|
|
|
return $this->configToken; |
216
|
|
|
} |
217
|
|
|
|
218
|
|
|
/** |
219
|
|
|
* @param string $configToken |
220
|
|
|
* @return JoinMeetingParameters |
221
|
|
|
*/ |
222
|
|
|
public function setConfigToken($configToken) |
223
|
|
|
{ |
224
|
|
|
$this->configToken = $configToken; |
225
|
|
|
|
226
|
|
|
return $this; |
227
|
|
|
} |
228
|
|
|
|
229
|
|
|
/** |
230
|
|
|
* @return string |
231
|
|
|
*/ |
232
|
|
|
public function getAvatarURL() |
233
|
|
|
{ |
234
|
|
|
return $this->avatarURL; |
235
|
|
|
} |
236
|
|
|
|
237
|
|
|
/** |
238
|
|
|
* @param string $avatarURL |
239
|
|
|
* @return JoinMeetingParameters |
240
|
|
|
*/ |
241
|
|
|
public function setAvatarURL($avatarURL) |
242
|
|
|
{ |
243
|
|
|
$this->avatarURL = $avatarURL; |
244
|
|
|
|
245
|
|
|
return $this; |
246
|
|
|
} |
247
|
|
|
|
248
|
|
|
/** |
249
|
|
|
* @return mixed |
250
|
|
|
*/ |
251
|
|
|
public function isRedirect() |
252
|
|
|
{ |
253
|
|
|
return $this->redirect; |
254
|
|
|
} |
255
|
|
|
|
256
|
|
|
/** |
257
|
|
|
* @param mixed $redirect |
258
|
|
|
* @return JoinMeetingParameters |
259
|
|
|
*/ |
260
|
|
|
public function setRedirect($redirect) |
261
|
|
|
{ |
262
|
|
|
$this->redirect = $redirect; |
263
|
|
|
|
264
|
|
|
return $this; |
265
|
|
|
} |
266
|
|
|
|
267
|
|
|
/** |
268
|
|
|
* @return mixed |
269
|
|
|
*/ |
270
|
|
|
public function getClientURL() |
271
|
|
|
{ |
272
|
|
|
return $this->clientURL; |
273
|
|
|
} |
274
|
|
|
|
275
|
|
|
/** |
276
|
|
|
* @param mixed $clientURL |
277
|
|
|
* @return JoinMeetingParameters |
278
|
|
|
*/ |
279
|
|
|
public function setClientURL($clientURL) |
280
|
|
|
{ |
281
|
|
|
$this->clientURL = $clientURL; |
282
|
|
|
|
283
|
|
|
return $this; |
284
|
|
|
} |
285
|
|
|
|
286
|
|
|
/** |
287
|
|
|
* @return string |
288
|
|
|
*/ |
289
|
|
|
public function getHTTPQuery() |
290
|
|
|
{ |
291
|
|
|
return $this->buildHTTPQuery( |
292
|
|
|
[ |
293
|
|
|
'meetingID' => $this->meetingId, |
294
|
|
|
'fullName' => $this->username, |
295
|
|
|
'password' => $this->password, |
296
|
|
|
'userID' => $this->userId, |
297
|
|
|
'webVoiceConf' => $this->webVoiceConf, |
298
|
|
|
'createTime' => $this->creationTime, |
299
|
|
|
'configToken' => $this->configToken, |
300
|
|
|
'avatarURL' => $this->avatarURL, |
301
|
|
|
'redirect' => $this->redirect, |
302
|
|
|
'clientURL' => $this->clientURL |
303
|
|
|
] |
304
|
|
|
); |
305
|
|
|
} |
306
|
|
|
} |
307
|
|
|
|
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.