Suggestions

close search

StringeeRoom

public class StringeeRoom
extends Object



Represents a Stringee room in which the client is participating.



Summary


Public Constructors
StringeeRoom(StringeeClient client)

Create a new StringeeRoom instance to make a room chat.

StringeeRoom(StringeeClient client, int roomId)

Create a new StringeeRoom instance to join the room chat.

Public methods
int getId()

Returns the room's id.

void joinRoom()

Joins the room chat. The StringeeRoom instance must be instantiated with the room's id before joining.

void leaveRoom()

Leaves the room chat and releases resources.

void makeRoom()

Makes a room chat.

void publish(StringeeStream stream)

Publishes a stream to the room.

void setRoomListener(StringeeRoomListener roomListener)

Sets a StringeeRoomListener object to monitor the room's events such as: connected, disconnected, streams added...

void subscribe(StringeeStream stream)

Subscribes a stream.

void unpublish(StringeeStream stream)

Unpublishes a stream.

void unsubscribe(StringeeStream stream)

Unsubscribes a stream.


Public constructors


StringeeRoom

StringeeRoom(StringeeClient client)

Create a new StringeeRoom instance to make a room chat.

Parameters
client

The client who wants to make a room chat.



StringeeRoom

StringeeRoom(StringeeClient client, int roomId)

Create a new StringeeRoom instance to join the room chat.

Parameters
client

The client who wants to join the room chat.

roomId

The room's id.



Public methods


getId

int getId()

Returns the room's id.



joinRoom

void joinRoom()

Joins the room chat. The StringeeRoom instance must be instantiated with the room's id before joining.



leaveRoom

void leaveRoom()

Leaves the room chat and releases resources.



makeRoom

void makeRoom()

Makes a room chat.



publish

void publish(StringeeStream stream)

Publishes a stream to the room.

Parameters
stream

The stream which will be published.



setRoomListener

void setRoomListener(StringeeRoomListener roomListener)

Sets a StringeeRoomListener object to monitor the room's events such as: connected, disconnected, streams added...

Parameters
roomListener

The StringeeRoomListener instance.



subscribe

void subscribe(StringeeStream stream)

Subscribes a stream.

Parameters
stream

The stream which will be subscribed.



unpublish

void unpublish(StringeeStream stream)

Unpublishes a stream.

Parameters
stream

The stream which will be unpublished.



unsubscribe

void unsubscribe(StringeeStream stream)

Unsubscribes a stream.

Parameters
stream

The stream which will be unsubscribed.