Bus inspired by BusIndexed but specific for function factory.

The implementation differs. In BusIndexed, each actor is indexed only once. Here, a single actor can be indexed multiple times (max 2).

Hierarchy (view full)

Constructors

Properties

actionIdentifierFields: string[]
actorIdentifierFields: string[]
actors: ActorFunctionFactory<undefined>[] = []
actorsIndex: Record<string, ActorFunctionFactory<undefined>[]> = {}
dependencyLinks: Map<ActorFunctionFactory<undefined>, ActorFunctionFactory<undefined>[]> = ...
failMessage: string
name: string

The name for this bus.

{<rdf:subject>}

Methods

  • Indicate that the given actor has the given actor dependencies.

    This will ensure that the given actor will be present in the bus before the given dependencies.

    Parameters

    • dependent: ActorFunctionFactory<undefined>

      A dependent actor that will be placed before the given actors.

    • dependencies: ActorFunctionFactory<undefined>[]

      Actor dependencies that will be placed after the given actor.

    Returns void

  • Unsubscribe the given actor from the bus.

    An actor that is subscribed multiple times will be unsubscribed only once.

    Parameters

    Returns boolean

    If the given actor was successfully unsubscribed, otherwise it was not subscribed before.