Setu-TS
    Preparing search index...

    Owns the set of live rooms, creating them on demand and dropping them once empty.

    0.1.0

    Index
    • Parameters

      • Optionalpublish: RoomPublisher

        Forwards every room broadcast to other replicas. Omit for purely in-process rooms, which is the behavior when no backplane capability is registered.

      • OptionalonMemberJoined: () => void

        Invoked whenever a connection joins any room on this replica. Used to open the backplane transport on demand: a replica with a local member has to be able to RECEIVE, and subscribing does not open a transport.

      Returns RoomRegistry

    • Delivers a frame that arrived from another replica to this replica's local members.

      A room is looked up but never CREATED here. A remote frame naming a room nobody on this replica has joined has no local audience, and creating one per arriving name would let a cluster-wide namespace grow this replica's room map without bound.

      Parameters

      • name: string

        The room the frame was addressed to

      • data: string | Uint8Array<ArrayBufferLike>

        The decoded payload

      • OptionalexceptId: string

        Connection ID the originating replica excluded, if any

      Returns void

      0.2.0

    • Returns the named room if one already exists, without creating it.

      The non-allocating counterpart to RoomRegistry.get. It is a bare map read by design: it must not touch RoomRegistry.#neverJoined in either direction, because adding to that set would mark a room already in use as abandoned, and reclaiming from it on a read path would make a lookup that promises to change nothing dispose rooms.

      Parameters

      • name: string

        Room name

      Returns Room | undefined

      The room, or undefined when no room of that name exists

      0.4.0