Hierarchy

Properties

addLibp2pEventListener: (<K>(type, listener, options?) => void)

Type declaration

    • <K>(type, listener, options?): void
    • Type Parameters

      • K extends keyof Libp2pEvents<ServiceMap>

      Parameters

      • type: K
      • listener: null | EventHandler<Libp2pEvents<ServiceMap>[K]>
      • Optional options: boolean | AddEventListenerOptions

      Returns void

multicodec: string
peerStore: PeerStore
peers: (() => Promise<Peer[]>)

Type declaration

    • (): Promise<Peer[]>
    • Returns Promise<Peer[]>

queryGenerator: (<T>(decoders, options?) => AsyncGenerator<Promise<undefined | T>[], any, unknown>)

Type declaration

    • <T>(decoders, options?): AsyncGenerator<Promise<undefined | T>[], any, unknown>
    • Type Parameters

      Parameters

      Returns AsyncGenerator<Promise<undefined | T>[], any, unknown>

queryWithOrderedCallback: (<T>(decoders, callback, options?) => Promise<void>)

Type declaration

    • <T>(decoders, callback, options?): Promise<void>
    • Type Parameters

      Parameters

      • decoders: IDecoder<T>[]
      • callback: ((message) => boolean | void | Promise<boolean | void>)
          • (message): boolean | void | Promise<boolean | void>
          • Parameters

            • message: T

            Returns boolean | void | Promise<boolean | void>

      • Optional options: StoreQueryOptions

      Returns Promise<void>

queryWithPromiseCallback: (<T>(decoders, callback, options?) => Promise<void>)

Type declaration

    • <T>(decoders, callback, options?): Promise<void>
    • Type Parameters

      Parameters

      • decoders: IDecoder<T>[]
      • callback: ((message) => boolean | void | Promise<boolean | void>)
          • (message): boolean | void | Promise<boolean | void>
          • Parameters

            • message: Promise<undefined | T>

            Returns boolean | void | Promise<boolean | void>

      • Optional options: StoreQueryOptions

      Returns Promise<void>

removeLibp2pEventListener: (<K>(type, listener?, options?) => void)

Type declaration

    • <K>(type, listener?, options?): void
    • Type Parameters

      • K extends keyof Libp2pEvents<ServiceMap>

      Parameters

      • type: K
      • Optional listener: null | EventHandler<Libp2pEvents<ServiceMap>[K]>
      • Optional options: boolean | EventListenerOptions

      Returns void

Generated using TypeDoc