Hierarchy

  • MembershipCache

Constructors

Methods

  • Gets the cached state of a user's membership for a room. This DOES NOT check to verify the value is correct (i.e the room may have state reset and left the user from the room).

    This only caches users from the appservice.

    Returns

    The membership state of the user, e.g. "joined"

    Parameters

    • roomId: string

      Room id to check the state of.

    • userId: string

      The userid to check the state of.

    Returns UserMembership

  • Gets the cached state of a user's membership for a room. This DOES NOT check to verify the value is correct (i.e the room may have state reset and left the user from the room).

    This only caches users from the appservice.

    Returns

    The member's profile information.

    Parameters

    • roomId: string

      Room id to check the state of.

    • userId: string

      The userid to check the state of.

    Returns UserProfile

  • Parameters

    Returns null | string[]

  • Is a user considered registered with the homeserver.

    Parameters

    • userId: string

      A Matrix userId

    Returns boolean

  • Set the cached state of a user's membership for a room. Use this to optimise intents so that they do not attempt to join a room if we know they are joined. This DOES NOT set the actual membership of the room.

    This only caches users from the appservice.

    Parameters

    • roomId: string

      Room id to set the state of.

    • userId: string

      The userid to set the state of.

    • membership: UserMembership

      The membership value to set for the user e.g joined.

    • profile: UserProfile

    Returns void

Generated using TypeDoc