You are here

public static function Channel::getAllChannelsBatched in Rocket.Chat 8.2

Retrieve Chat Public Channels list. (in batch size).

@todo needs better Error checking / missing detection.

Parameters

\Drupal\rocket_chat_api\RocketChat\ApiClient $api:

array $channels:

int $offset:

int $size:

Return value

int Total number of Channels found.

1 call to Channel::getAllChannelsBatched()
Channels::refreshCache in modules/rocket_chat_api/src/RocketChat/Collection/Channels.php

File

modules/rocket_chat_api/src/RocketChat/Element/Channel.php, line 208

Class

Channel

Namespace

Drupal\rocket_chat_api\RocketChat\Element

Code

public static function getAllChannelsBatched(ApiClient &$api, array &$channels, $offset = 0, $size = 500) {
  return self::getAllRoomsBatched($api, $channels, "channels.list", $offset, $size);
}