Meeting
Represents a live meeting session containing participants, streams, and associated states.
This class maintains references to the local participant, remote participants, pinned participants, and streaming/recording/transcription states. It also provides access to PubSub messaging, RealtimeStore, and custom media streams.
Obtain an instance using initMeeting and call join to connect.
Meeting actions need a joined meeting. Every action here — and on Participant, Stream, PubSub and RealtimeStore — checks the meeting state first and does nothing if it cannot run, so no request is sent and no local state changes. onError reports which check failed:
- Called before join completes, or after the meeting left or failed — code
3001(ERROR_ACTION_PERFORMED_BEFORE_MEETING_JOINED), whose message names the method that was rejected. - Called while the meeting is RECONNECTING — code
3014(ERROR_MEETING_RECONNECTING). Rejected calls are not replayed once the meeting reconnects; call them again after onMeetingStateChanged reports CONNECTED.
A third code covers what the checks cannot: an action that passed its check while the meeting was connected, but never reached the server because the meeting was left or ended first. That arrives as 3015 (ERROR_OPERATION_ABORTED) rather than 3001, because the meeting was joined at the time of the call.
Exempt are join, listener registration, the read-only accessors and stopObserving, whose removal is local. leave follows its own, looser rule — available while the meeting is connected or reconnecting, rejected otherwise — spelled out on leave.
Two surfaces add a second channel on top of the error event. PubSub also throws an IllegalStateException on the calling thread, and the methods that take a callback — set, get, uploadBase64File and fetchBase64File — also deliver the same message to that callback, so a caller awaiting it is not left hanging.