Options
All
  • Public
  • Public/Protected
  • All
Menu

The client returned from subscribing as a secondary node to a search topic, which is managed by a primary node. Can be used to interact with a search topic.

Hierarchy

Index

Methods

deregister

  • deregister(name: string): Promise<void>
  • Deregister a search provider by its name.

    Parameters

    • name: string

      the name of the search provider to deregister

    Returns Promise<void>

disconnect

  • disconnect(): Promise<void>
  • Disconnect from the search topic. NOTE: All search providers registered by this search client will be deregistered.

    Returns Promise<void>

dispatch

  • dispatch(providerName: string, result: SearchResult, action: string): Promise<any>
  • Dispatch a search result back to the search provider. It is then the search providers duty to perform what ever action was chosen.

    Parameters

    • providerName: string

      the name of the search provider to send the search result back to.

    • result: SearchResult

      the search result to send back to the search provider.

    • action: string

      the action for the search provider to perform with the search result.

    Returns Promise<any>

getAllProviders

  • Obtain information about all search providers listening in on the topic.

    Returns Promise<SearchProviderInfo[]>

register

  • Register a search provider.

    Parameters

    Returns Promise<void>

search

  • Execute a search on the search topic.

    The generator returned by this function can be called multiple times, returning the current list of search provider responses. As more search providers respond to the search request the returned list of responses will grow in length.

    When all the search providers have responded to the search request, the generator will return the final set of search response under the value attribute and set the 'done' attribute set to true.

    If no targets are included in request, will search against all search providers.

    experimental

    Parameters

    • request: SearchRequest

      the request object that contains parameters to base the search on.

    Returns Promise<SearchProviderResponseGeneratorExtended>

Legend

  • Property
  • Method

Generated using TypeDoc