Hierarchy

  • RemoteRoom

Constructors

Properties

Methods

Constructors

  • Create a remote room.

    Parameters

    • roomId: string
    • data: Record<string, unknown> = {}

      The key-value data object to assign to this room.

    Returns RemoteRoom

Properties

data: Record<string, unknown> = {}

The key-value data object to assign to this room.

roomId: string

Methods

  • Get the data value for the given key.

    Returns

    Stored data for this key. May be undefined.

    Type Parameters

    • T

    Parameters

    • key: string

      An arbitrary bridge-specific key.

    Returns T

  • Get the room ID.

    Returns

    The room ID

    Returns string

  • Serialize all the data about this room, excluding the room ID.

    Returns

    The serialised data

    Returns Record<string, unknown>

  • Set an arbitrary bridge-specific data value for this room.

    Parameters

    • key: string

      The key to store the data value under.

    • val: unknown

      The data value. This value should be serializable via JSON.stringify(data).

    Returns void

Generated using TypeDoc