groupId = $groupId; $this->remainingMessages = $remainingMessages; $this->timeout = $hasTimedOut; } public function isDone(): bool { return $this->remainingMessages === []; } /** @return MessageUpdateParameter[] */ public function getRemainingMessages(): array { return $this->remainingMessages; } public function getGroupId(): string { return $this->groupId; } public function hasTimedOut(): bool { return $this->timeout; } /** @return mixed[] */ protected function toJsonArray(): array { return get_object_vars( $this ); } public static function newFromJsonArray( JsonUnserializer $unserializer, array $params ) { return new self( $params['groupId'], $params['remainingMessages'], $params['timeout'] ); } }