Strophe.js
    Preparing search index...

    Interface StreamManagementController

    The Stream Management surface a page-side Connection depends on, implemented by both the worker-free engine (engine.ts) and the worker-mode page mirror (mirror.ts). Typing Connection.sm against this (rather than the concrete engine class) is what lets the mirror be a peer implementation instead of a subclass full of neutralised overrides: any member added here must be implemented by both sides, so the mirror can never silently inherit a live engine method it was meant to render inert.

    interface StreamManagementController {
        boundJid: string;
        enabled: boolean;
        resumed: boolean;
        resumePending: boolean;
        serverSupported: boolean;
        state: SMState;
        hasResumableState(): boolean;
        initialize(jid: string): void;
        isTracking(): boolean;
        onEnabled(): void;
        onFailed(view?: StanzaView, resumeFailed?: boolean): void;
        onGracefulClose(): void;
        onInbound(view: StanzaView): void;
        onInboundStanza(name: string): void;
        onResumed(): void;
        reset(): void;
        sendEnable(boundJid: string): void;
        sendResume(): void;
        trackOutbound(view: StanzaView): void;
    }

    Implemented by

    Index
    boundJid: string

    The full JID bound when the session was enabled.

    enabled: boolean

    Whether has been received and the session is active.

    resumed: boolean

    Whether the current session was established by resumption.

    resumePending: boolean

    Whether a has been sent and not yet answered.

    serverSupported: boolean

    Whether the current stream's features advertised .

    state: SMState

    The live SM session state (fields are mutable; the reference is not reassigned).

    • Load persisted resumable state for the given (bare) JID.

      Parameters

      • jid: string

      Returns void