Adds a new event listener for the specified event. The class will ignore duplicate registrations of the same listener to the same event.
The name of the event to add the listener for.
The listener callback to register.
This object, in support of a fluent API.
Provides the events emitted by this object as an Observable stream.
An Observable stream of all events emitted by this object.
Determines if an Activity with the specified id is already joined.
The user defined type of activity.
The id (unique within the type) of the Activity to check.
True if the Activity with the specified id is joined; false otherwise.
Allows the connected user to join the specified activity.
const activityId = "myActivityId";
activityService
.join(activityId)
.then(activity => {
console.log("Joined!");
console.log(activity.participants());
});
.catch(e => console.error(e));
The user defined type of the Activity to join.
The unique id (within the type) of the Activity to join.
Options for connecting to the specified Activity.
A Promise that will be resolved with the successfully joined Activity.
Provides a map of all currently joined Activities.
A Map of Activity Id => Activity.
Removes a single event listener for a specific event.
The name of the event to remove the listener for.
The listener callback to unregister.
This object, in support of a fluent API.
Adds a new event listener for the specified event. The class will ignore duplicate registrations of the same listener to the same event.
The name of the event to add the listener for.
The listener callback to register.
This object, in support of a fluent API.
Adds a single shot event listener for the specified event. The listener will be called the first time the specified event is fired after the event registration occurs, after which the registration will be removed and no further events will be passed to the listener.
The name of the event to add the listener for.
The listener callback to register.
This object, in support of a fluent API.
Removes all listeners for all events. This is useful for cleanup before disposing of this particular event emitter.
This object, in support of a fluent API.
Removes a single event listener for a specific event.
The name of the event to remove the listener for.
The listener callback to unregister.
This object, in support of a fluent API.
Removes all listeners bound on the given event.
the name of the event to remove listeners for
This object, in support of a fluent API.
The current Convergence ConvergenceSession object that represents the connection to the Convergence Domain.
The ActivityService provides the main entry point into working with Activities in Convergence. Activities provide a mechanism to communicate
where
users are operating within a system andwhat
they are doing.See the developer guide for an introduction to Activities.