Skip to content

Commit

Permalink
Add return types to the implemented functions
Browse files Browse the repository at this point in the history
  • Loading branch information
ajrice6713 committed May 17, 2023
1 parent 2c44088 commit bb616e6
Show file tree
Hide file tree
Showing 40 changed files with 42 additions and 41 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@
vendor
composer.lock
.phpunit.result.cache
composer.phar
composer.phar
.idea
2 changes: 1 addition & 1 deletion src/Messaging/Models/BandwidthCallbackMessage.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['time'] = $this->time;
Expand Down
2 changes: 1 addition & 1 deletion src/Messaging/Models/BandwidthMessage.php
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['id'] = $this->id;
Expand Down
2 changes: 1 addition & 1 deletion src/Messaging/Models/BandwidthMessageItem.php
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['messageId'] = $this->messageId;
Expand Down
2 changes: 1 addition & 1 deletion src/Messaging/Models/BandwidthMessagesList.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['totalCount'] = $this->totalCount;
Expand Down
2 changes: 1 addition & 1 deletion src/Messaging/Models/DeferredResult.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['result'] = $this->result;
Expand Down
2 changes: 1 addition & 1 deletion src/Messaging/Models/Media.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['content'] = $this->content;
Expand Down
2 changes: 1 addition & 1 deletion src/Messaging/Models/MessageRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['applicationId'] = $this->applicationId;
Expand Down
2 changes: 1 addition & 1 deletion src/Messaging/Models/PageInfo.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['prevPage'] = $this->prevPage;
Expand Down
2 changes: 1 addition & 1 deletion src/Messaging/Models/Tag.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['key'] = $this->key;
Expand Down
2 changes: 1 addition & 1 deletion src/MultiFactorAuth/Models/TwoFactorCodeRequestSchema.php
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['to'] = $this->to;
Expand Down
2 changes: 1 addition & 1 deletion src/MultiFactorAuth/Models/TwoFactorMessagingResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['messageId'] = $this->messageId;
Expand Down
2 changes: 1 addition & 1 deletion src/MultiFactorAuth/Models/TwoFactorVerifyCodeResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['valid'] = $this->valid;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['to'] = $this->to;
Expand Down
2 changes: 1 addition & 1 deletion src/MultiFactorAuth/Models/TwoFactorVoiceResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['callId'] = $this->callId;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/CallCallback.php
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['eventType'] = $this->eventType;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/CallRecordingMetadata.php
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['applicationId'] = $this->applicationId;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/CallState.php
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['callId'] = $this->callId;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/ConferenceCallback.php
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['conferenceId'] = $this->conferenceId;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/ConferenceMemberState.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['callId'] = $this->callId;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/ConferenceRecordingMetadata.php
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['accountId'] = $this->accountId;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/ConferenceState.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['id'] = $this->id;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/CreateCallRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['from'] = $this->from;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/CreateCallResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['accountId'] = $this->accountId;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/Diversion.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['reason'] = $this->reason;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/MachineDetectionConfiguration.php
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['mode'] = $this->mode;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/ModifyCallRecordingRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['state'] = $this->state;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/ModifyCallRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['state'] = $this->state;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/ModifyConferenceRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['status'] = $this->status;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/TranscribeRecordingRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['callbackUrl'] = $this->callbackUrl;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/Transcript.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['text'] = $this->text;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/Transcription.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['id'] = $this->id;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/TranscriptionMetadata.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['id'] = $this->id;
Expand Down
2 changes: 1 addition & 1 deletion src/Voice/Models/TranscriptionResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['transcripts'] = isset($this->transcripts) ?
Expand Down
2 changes: 1 addition & 1 deletion src/WebRtc/Models/AccountsParticipantsResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['participant'] = $this->participant;
Expand Down
2 changes: 1 addition & 1 deletion src/WebRtc/Models/Participant.php
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['id'] = $this->id;
Expand Down
2 changes: 1 addition & 1 deletion src/WebRtc/Models/ParticipantSubscription.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['participantId'] = $this->participantId;
Expand Down
2 changes: 1 addition & 1 deletion src/WebRtc/Models/Session.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['id'] = $this->id;
Expand Down
2 changes: 1 addition & 1 deletion src/WebRtc/Models/Subscriptions.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public function __construct()
/**
* Encode this object to JSON
*/
public function jsonSerialize()
public function jsonSerialize(): array
{
$json = array();
$json['sessionId'] = $this->sessionId;
Expand Down
4 changes: 2 additions & 2 deletions tests/ApiTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ public function testCreateCallAndGetCallState() {
$this->assertTrue(strlen($callId) > 0);
$this->assertTrue(is_a($response->getResult()->enqueuedTime, 'DateTime'));

sleep(1);
sleep(15);

//get phone call information
$response = $this->bandwidthClient->getVoice()->getClient()->getCall(getenv("BW_ACCOUNT_ID"), $callId);
Expand Down Expand Up @@ -120,7 +120,7 @@ public function testCreateCallWithAmdAndGetCallState() {
$callId = $response->getResult()->callId;
$this->assertTrue(strlen($callId) > 0);

sleep(1);
sleep(15);

//get phone call information
$response = $this->bandwidthClient->getVoice()->getClient()->getCall(getenv("BW_ACCOUNT_ID"), $callId);
Expand Down

0 comments on commit bb616e6

Please sign in to comment.