count

// Using callbacks (NodeJS or Web Browser)
room.count(function (error, result) {
  // ...
});

// Using promises (NodeJS)
room.countPromise().then(result => {
  // ...
});
room.count(new ResponseListener<Integer>() {
 @Override
 public void onSuccess(Integer result) throws Exception {
   //  ...
 }

 @Override
 public void onError(JSONObject error) throws Exception {
   // Handle error
 }
});
<?php

// not implemented (this SDK uses HTTP and is thus stateless)

Callback response

1

Return the number of subscribers on that room


count(callback)

ArgumentsTypeDescription
callbackfunctionCallback handling the response

Callback response

Resolves to a integer containing the number of users subscribing to this room.