Skip to content

Commit 22385bb

Browse files
committed
Implement features for BigBlueButton 2.6
1 parent e28b964 commit 22385bb

11 files changed

+74
-31
lines changed

README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
![Home Image](https://raw.githubusercontent.com/wiki/bigbluebutton/bigbluebutton-api-php/images/header.png)
44
[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fbigbluebutton%2Fbigbluebutton-api-php.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2Fbigbluebutton%2Fbigbluebutton-api-php?ref=badge_shield)
55

6-
The official and easy to use **BigBlueButton API for PHP**, makes easy for developers to use [BigBlueButton][bbb] API for **PHP 7.3+**.
6+
The official and easy to use **BigBlueButton API for PHP**, makes easy for developers to use [BigBlueButton][bbb] API for **PHP 7.4+**.
77

88
![Packagist](https://img.shields.io/packagist/v/bigbluebutton/bigbluebutton-api-php.svg?label=release)
99
![PHP from Travis config](https://img.shields.io/travis/php-v/bigbluebutton/bigbluebutton-api-php.svg)
@@ -16,7 +16,6 @@ The official and easy to use **BigBlueButton API for PHP**, makes easy for devel
1616
[![@bigbluebutton on Twitter](https://img.shields.io/badge/twitter-%40bigbluebutton-blue.svg?style=flat)](https://twitter.com/bigbluebutton)
1717
![Website](https://img.shields.io/website-up-down-green-red/http/bigbluebutton.org.svg?label=BigBlueButton.org)
1818

19-
[![PHP 7.3](https://img.shields.io/badge/php-7.3-f33.svg?style=flat-square)](https://www.php.net/supported-versions.php)
2019
[![PHP 7.4](https://img.shields.io/badge/php-7.4-f33.svg?style=flat-square)](https://www.php.net/supported-versions.php)
2120
[![PHP 8.0](https://img.shields.io/badge/php-8.0-f93.svg?style=flat-square)](https://www.php.net/supported-versions.php)
2221
[![PHP 8.1](https://img.shields.io/badge/php-8.1-9c9.svg?style=flat-square)](https://www.php.net/supported-versions.php)

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
}
2424
},
2525
"require": {
26-
"php": ">=7.1",
26+
"php": ">=7.4",
2727
"ext-curl": "*",
2828
"ext-simplexml": "*",
2929
"ext-mbstring": "*",

src/Enum/Feature.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,4 +34,6 @@ class Feature extends Enum
3434
public const SCREENSHARE = 'screenshare';
3535
public const SHARED_NOTES = 'sharedNotes';
3636
public const VIRTUAL_BACKGROUNDS = 'virtualBackgrounds';
37+
public const LIVE_TRANSCRIPTION = 'liveTranscription';
38+
public const PRESENTATION = 'presentation';
3739
}

src/Parameters/CreateMeetingParameters.php

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -330,12 +330,12 @@ class CreateMeetingParameters extends MetaParameters
330330
/**
331331
* @var string
332332
*/
333-
private $uploadExternalUrl;
333+
private $presentationUploadExternalUrl;
334334

335335
/**
336336
* @var string
337337
*/
338-
private $uploadExternalDescription;
338+
private $presentationUploadExternalDescription;
339339

340340
/**
341341
* CreateMeetingParameters constructor.
@@ -1470,32 +1470,32 @@ public function setNotifyRecordingIsOn(bool $notifyRecordingIsOn): CreateMeeting
14701470
return $this;
14711471
}
14721472

1473-
public function getUploadExternalUrl(): string
1473+
public function getPresentationUploadExternalUrl(): string
14741474
{
1475-
return $this->uploadExternalUrl;
1475+
return $this->presentationUploadExternalUrl;
14761476
}
14771477

14781478
/**
14791479
* @return $this
14801480
*/
1481-
public function setUploadExternalUrl(string $uploadExternalUrl): CreateMeetingParameters
1481+
public function setPresentationUploadExternalUrl(string $presentationUploadExternalUrl): CreateMeetingParameters
14821482
{
1483-
$this->uploadExternalUrl = $uploadExternalUrl;
1483+
$this->presentationUploadExternalUrl = $presentationUploadExternalUrl;
14841484

14851485
return $this;
14861486
}
14871487

1488-
public function getUploadExternalDescription(): string
1488+
public function getPresentationUploadExternalDescription(): string
14891489
{
1490-
return $this->uploadExternalDescription;
1490+
return $this->presentationUploadExternalDescription;
14911491
}
14921492

14931493
/**
14941494
* @return $this
14951495
*/
1496-
public function setUploadExternalDescription(string $uploadExternalDescription): CreateMeetingParameters
1496+
public function setPresentationUploadExternalDescription(string $presentationUploadExternalDescription): CreateMeetingParameters
14971497
{
1498-
$this->uploadExternalDescription = $uploadExternalDescription;
1498+
$this->presentationUploadExternalDescription = $presentationUploadExternalDescription;
14991499

15001500
return $this;
15011501
}
@@ -1558,8 +1558,8 @@ public function getHTTPQuery()
15581558
'preUploadedPresentationOverrideDefault' => $this->preUploadedPresentationOverrideDefault,
15591559
'disabledFeatures' => join(',', $this->disabledFeatures),
15601560
'notifyRecordingIsOn' => $this->notifyRecordingIsOn ? 'true' : 'false',
1561-
'uploadExternalUrl' => $this->uploadExternalUrl,
1562-
'uploadExternalDescription' => $this->uploadExternalDescription,
1561+
'presentationUploadExternalUrl' => $this->presentationUploadExternalUrl,
1562+
'presentationUploadExternalDescription' => $this->presentationUploadExternalDescription,
15631563
];
15641564

15651565
// Add breakout rooms parameters only if the meeting is a breakout room

src/Parameters/GetMeetingInfoParameters.php

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,16 @@ class GetMeetingInfoParameters extends BaseParameters
3030
*/
3131
private $meetingId;
3232

33+
/**
34+
* @var int
35+
*/
36+
private $offset;
37+
38+
/**
39+
* @var int
40+
*/
41+
private $limit;
42+
3343
/**
3444
* GetMeetingInfoParameters constructor.
3545
*
@@ -60,6 +70,30 @@ public function setMeetingId($meetingId)
6070
return $this;
6171
}
6272

73+
public function getOffset(): int
74+
{
75+
return $this->offset;
76+
}
77+
78+
public function setOffset(int $offset): GetMeetingInfoParameters
79+
{
80+
$this->offset = $offset;
81+
82+
return $this;
83+
}
84+
85+
public function getLimit(): int
86+
{
87+
return $this->limit;
88+
}
89+
90+
public function setLimit(int $limit): GetMeetingInfoParameters
91+
{
92+
$this->limit = $limit;
93+
94+
return $this;
95+
}
96+
6397
/**
6498
* @return string
6599
*/
@@ -68,6 +102,8 @@ public function getHTTPQuery()
68102
return $this->buildHTTPQuery(
69103
[
70104
'meetingID' => $this->meetingId,
105+
'offset' => $this->offset,
106+
'limit' => $this->limit,
71107
]
72108
);
73109
}

src/Parameters/GetRecordingTextTracksParameters.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@ class GetRecordingTextTracksParameters extends MetaParameters
3232

3333
/**
3434
* GetRecordingTextTracksParameters constructor.
35+
*
36+
* @param mixed $recordId
3537
*/
3638
public function __construct($recordId)
3739
{

src/Parameters/JoinMeetingParameters.php

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -88,17 +88,17 @@ class JoinMeetingParameters extends UserDataParameters
8888
* @var bool
8989
*/
9090
private $excludeFromDashboard;
91-
91+
9292
/**
9393
* @var string
9494
*/
9595
private $configToken;
96-
96+
9797
/**
9898
* @var bool
9999
*/
100100
private $guest;
101-
101+
102102
/**
103103
* @var string
104104
*/
@@ -343,7 +343,7 @@ public function setExcludeFromDashboard($excludeFromDashboard): JoinMeetingParam
343343

344344
return $this;
345345
}
346-
346+
347347
/**
348348
* @return string
349349
*/
@@ -363,7 +363,7 @@ public function setConfigToken($configToken)
363363

364364
return $this;
365365
}
366-
366+
367367
/**
368368
* @return bool
369369
*/
@@ -383,7 +383,7 @@ public function setGuest($guest)
383383

384384
return $this;
385385
}
386-
386+
387387
/**
388388
* @return string
389389
*/
@@ -434,9 +434,9 @@ public function getHTTPQuery()
434434
'avatarURL' => $this->avatarURL,
435435
'redirect' => $this->redirect ? 'true' : 'false',
436436
'clientURL' => $this->clientURL,
437-
'configToken' => $this->configToken,
438-
'guest' => $this->guest ? 'true' : 'false',
439-
'defaultLayout' => $this->defaultLayout,
437+
'configToken' => $this->configToken,
438+
'guest' => $this->guest ? 'true' : 'false',
439+
'defaultLayout' => $this->defaultLayout,
440440
];
441441

442442
foreach ($this->customParameters as $key => $value) {

tests/Parameters/CreateMeetingParametersTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,8 +94,8 @@ public function testCreateMeetingParameters()
9494
$this->assertEquals($params['meta_bbb-recording-ready-url'], $createMeetingParams->getMeta('bbb-recording-ready-url'));
9595

9696
$this->assertEquals($params['notifyRecordingIsOn'], $createMeetingParams->getNotifyRecordingIsOn());
97-
$this->assertEquals($params['uploadExternalUrl'], $createMeetingParams->getUploadExternalUrl());
98-
$this->assertEquals($params['uploadExternalDescription'], $createMeetingParams->getUploadExternalDescription());
97+
$this->assertEquals($params['presentationUploadExternalUrl'], $createMeetingParams->getPresentationUploadExternalUrl());
98+
$this->assertEquals($params['presentationUploadExternalDescription'], $createMeetingParams->getPresentationUploadExternalDescription());
9999

100100
// Check values are empty of this is not a breakout room
101101
$this->assertNull($createMeetingParams->isBreakout());

tests/Parameters/GetMeetingInfoParametersTest.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,10 @@ public function testGetMeetingInfoParameters()
3737

3838
// Test setters that are ignored by the constructor
3939
$getMeetingInfoParams->setMeetingId($newId = $this->faker->uuid);
40+
$getMeetingInfoParams->setMeetingId($limit = $this->faker->numberBetween(1, 99));
41+
$getMeetingInfoParams->setMeetingId($offset = $this->faker->numberBetween(1, 99));
4042
$this->assertEquals($newId, $getMeetingInfoParams->getMeetingId());
43+
$this->assertEquals($limit, $getMeetingInfoParams->getLimit());
44+
$this->assertEquals($offset, $getMeetingInfoParams->getOffset());
4145
}
4246
}

tests/Parameters/JoinMeetingParametersTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@
2020

2121
namespace BigBlueButton\Parameters;
2222

23-
use BigBlueButton\Enum\Role;
2423
use BigBlueButton\Enum\MeetingLayout;
24+
use BigBlueButton\Enum\Role;
2525
use BigBlueButton\TestCase;
2626

2727
/**

0 commit comments

Comments
 (0)