Type alias RoomStateEventHandlerMap

RoomStateEventHandlerMap: {
    Beacon.new: ((event: MatrixEvent, beacon: Beacon) => void);
    RoomState.BeaconLiveness: ((state: RoomState, hasLiveBeacons: boolean) => void);
    RoomState.Marker: ((event: MatrixEvent, setStateOptions?: IMarkerFoundOptions) => void);
    RoomState.events: ((event: MatrixEvent, state: RoomState, lastStateEvent: MatrixEvent | null) => void);
    RoomState.members: ((event: MatrixEvent, state: RoomState, member: RoomMember) => void);
    RoomState.newMember: ((event: MatrixEvent, state: RoomState, member: RoomMember) => void);
    RoomState.update: ((state: RoomState) => void);
}

Type declaration

  • Beacon.new: ((event: MatrixEvent, beacon: Beacon) => void)
  • RoomState.BeaconLiveness: ((state: RoomState, hasLiveBeacons: boolean) => void)
      • (state: RoomState, hasLiveBeacons: boolean): void
      • Parameters

        Returns void

  • RoomState.Marker: ((event: MatrixEvent, setStateOptions?: IMarkerFoundOptions) => void)
  • RoomState.events: ((event: MatrixEvent, state: RoomState, lastStateEvent: MatrixEvent | null) => void)
      • (event: MatrixEvent, state: RoomState, lastStateEvent: MatrixEvent | null): void
      • Fires whenever the event dictionary in room state is updated.

        Example

        matrixClient.on("RoomState.events", function(event, state, prevEvent){
        var newStateEvent = event;
        });

        Parameters

        • event: MatrixEvent

          The matrix event which caused this event to fire.

        • state: RoomState

          The room state whose RoomState.events dictionary was updated.

        • lastStateEvent: MatrixEvent | null

        Returns void

  • RoomState.members: ((event: MatrixEvent, state: RoomState, member: RoomMember) => void)
      • (event: MatrixEvent, state: RoomState, member: RoomMember): void
      • Fires whenever a member in the members dictionary is updated in any way.

        Example

        matrixClient.on("RoomState.members", function(event, state, member){
        var newMembershipState = member.membership;
        });

        Parameters

        • event: MatrixEvent

          The matrix event which caused this event to fire.

        • state: RoomState

          The room state whose RoomState.members dictionary was updated.

        • member: RoomMember

          The room member that was updated.

        Returns void

  • RoomState.newMember: ((event: MatrixEvent, state: RoomState, member: RoomMember) => void)
      • (event: MatrixEvent, state: RoomState, member: RoomMember): void
      • Fires whenever a member is added to the members dictionary. The RoomMember will not be fully populated yet (e.g. no membership state) but will already be available in the members dictionary.

        Example

        matrixClient.on("RoomState.newMember", function(event, state, member){
        // add event listeners on 'member'
        });

        Parameters

        • event: MatrixEvent

          The matrix event which caused this event to fire.

        • state: RoomState

          The room state whose RoomState.members dictionary was updated with a new entry.

        • member: RoomMember

          The room member that was added.

        Returns void

  • RoomState.update: ((state: RoomState) => void)

Generated using TypeDoc