ic-reactor
    Preparing search index...

    Interface AgentManager

    interface AgentManager {
        agentStore: types.AgentStore;
        authStore: types.AuthStore;
        initializeAgent: () => Promise<void>;
        subscribeAgent: (
            callback: (agent: types.HttpAgent) => void,
            initialize?: boolean,
        ) => () => void;
        unsubscribeAgent: (callback: (agent: types.HttpAgent) => void) => void;
        updateAgent: (options?: types.UpdateAgentParameters) => Promise<void>;
        authenticate: () => Promise<types.Identity>;
        login: (options?: types.AuthClientLoginOptions) => Promise<void>;
        logout: (options?: { returnTo?: string }) => Promise<void>;
        getAgent: () => types.HttpAgent;
        getAgentHost: () => undefined | URL;
        getAgentHostName: () => string;
        getIsLocal: () => boolean;
        isAuthClientInitialized: () => boolean;
        getNetwork: () => "local" | "remote" | "ic";
        getAgentState: () => types.AgentState;
        subscribeAgentState: {
            (
                listener: (
                    selectedState: types.AgentState,
                    previousSelectedState: types.AgentState,
                ) => void,
            ): () => void;
            <U>(
                selector: (state: types.AgentState) => U,
                listener: (selectedState: U, previousSelectedState: U) => void,
                options?: {
                    equalityFn?: (a: U, b: U) => boolean;
                    fireImmediately?: boolean;
                },
            ): () => void;
        };
        getAuthState: () => types.AuthState;
        subscribeAuthState: {
            (
                listener: (
                    selectedState: types.AuthState,
                    previousSelectedState: types.AuthState,
                ) => void,
            ): () => void;
            <U>(
                selector: (state: types.AuthState) => U,
                listener: (selectedState: U, previousSelectedState: U) => void,
                options?: {
                    equalityFn?: (a: U, b: U) => boolean;
                    fireImmediately?: boolean;
                },
            ): () => void;
        };
        getAuth: () => null | types.AuthClient;
        getIdentity: () => null | types.Identity;
        getPrincipal: () => null | types.Principal;
    }

    Hierarchy (View Summary)

    Index

    Properties

    agentStore: types.AgentStore
    authStore: types.AuthStore
    initializeAgent: () => Promise<void>
    subscribeAgent: (
        callback: (agent: types.HttpAgent) => void,
        initialize?: boolean,
    ) => () => void
    unsubscribeAgent: (callback: (agent: types.HttpAgent) => void) => void
    updateAgent: (options?: types.UpdateAgentParameters) => Promise<void>
    authenticate: () => Promise<types.Identity>
    login: (options?: types.AuthClientLoginOptions) => Promise<void>
    logout: (options?: { returnTo?: string }) => Promise<void>
    getAgent: () => types.HttpAgent
    getAgentHost: () => undefined | URL
    getAgentHostName: () => string
    getIsLocal: () => boolean
    isAuthClientInitialized: () => boolean
    getNetwork: () => "local" | "remote" | "ic"
    getAgentState: () => types.AgentState
    subscribeAgentState: {
        (
            listener: (
                selectedState: types.AgentState,
                previousSelectedState: types.AgentState,
            ) => void,
        ): () => void;
        <U>(
            selector: (state: types.AgentState) => U,
            listener: (selectedState: U, previousSelectedState: U) => void,
            options?: {
                equalityFn?: (a: U, b: U) => boolean;
                fireImmediately?: boolean;
            },
        ): () => void;
    }
    getAuthState: () => types.AuthState
    subscribeAuthState: {
        (
            listener: (
                selectedState: types.AuthState,
                previousSelectedState: types.AuthState,
            ) => void,
        ): () => void;
        <U>(
            selector: (state: types.AuthState) => U,
            listener: (selectedState: U, previousSelectedState: U) => void,
            options?: {
                equalityFn?: (a: U, b: U) => boolean;
                fireImmediately?: boolean;
            },
        ): () => void;
    }
    getAuth: () => null | types.AuthClient
    getIdentity: () => null | types.Identity
    getPrincipal: () => null | types.Principal