Comunica Link Traversal
    Preparing search index...

    Class ActorExtractLinks<TS>Abstract

    A comunica actor for extract-links events.

    Actor types:

    • Input: IActionExtractLinks: Metdata from which links can be extracted.
    • Test:
    • Output: IActorExtractLinksOutput: The extracted links.
    • IActionExtractLinks
    • IActorExtractLinksOutput

    Type Parameters

    • TS = undefined

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    beforeActors: Actor<
        IActionExtractLinks,
        IActorTest,
        IActorExtractLinksOutput,
        TS,
    >[]

    Actor that must be registered in the bus before this actor.

    bus: Bus<
        Actor<IActionExtractLinks, IActorTest, IActorExtractLinksOutput, TS>,
        IActionExtractLinks,
        IActorTest,
        IActorExtractLinksOutput,
        TS,
    >

    The bus this actor subscribes to.

    name: string

    The name for this actor.

    {<rdf:subject>}
    

    Methods

    • Parameters

      • context: IActionContext
      • Optionaldata: () => any

      Returns any

    • Parameters

      • context: IActionContext
      • message: string
      • Optionaldata: () => any

      Returns void

    • Parameters

      • context: IActionContext
      • message: string
      • Optionaldata: () => any

      Returns void

    • Parameters

      • context: IActionContext
      • message: string
      • Optionaldata: () => any

      Returns void

    • Parameters

      • context: IActionContext
      • message: string
      • Optionaldata: () => any

      Returns void

    • Parameters

      • context: IActionContext
      • message: string
      • Optionaldata: () => any

      Returns void

    • Parameters

      • context: IActionContext
      • message: string
      • Optionaldata: () => any

      Returns void

    • Run the given action on this actor.

      In most cases, this method should not be called directly. Instead, #runObservable should be called.

      Parameters

      Returns Promise<IActorExtractLinksOutput>

      A promise that resolves to the run result.

    • Check if this actor can run the given action, without actually running it.

      Parameters

      Returns Promise<TestResult<IActorTest, TS>>

      A promise that resolves to the test result.

    • A helper function to append links based on incoming quads.

      Parameters

      • metadata: Stream

        A metadata stream of quads.

      • onQuad: (quad: Quad, links: ILink[]) => void

        A callback that will be invoked for each quad in the metadata stream. The second argument is the array of links that can be appended to.

      Returns Promise<ILink[]>

    • Get the logger from the given context.

      Parameters

      • context: IActionContext

        An optional context.

      Returns Logger | undefined

      The logger or undefined.