Class Signals<T, TR>

Signals/Slots, you can associate multiple Slots with Signals, when Signals generate signals, Slots will be called in turn

Type Parameters

  • T

  • TR

Hierarchy

  • Signals

Constructors

  • Type Parameters

    • T

    • TR

    Parameters

    Returns Signals<T, TR>

Properties

combiner?: Combiner<T, TR>
cons_: Connection<T, TR>[] = ...

Connected Signals/Slots

Accessors

  • get conns(): Iterator<Connection<T, TR>, any, undefined>
  • Returns an iterator to iterate over all connections

    Returns Iterator<Connection<T, TR>, any, undefined>

  • get isEmpty(): boolean
  • if there is no connections return it rue

    Returns boolean

  • get length(): number
  • Returns the number of connections

    Returns number

  • get slots(): Iterator<Slot<T, TR>, any, undefined>
  • Returns an iterator to iterate over all slots

    Returns Iterator<Slot<T, TR>, any, undefined>

  • get value(): undefined | TR
  • If there is a combiner, return the latest value of the combiner

    Returns undefined | TR

Methods

  • connect Slots to Signals

    Returns

    Parameters

    • slot: Slot<T, TR>
    • Optional tag: any

      Slots group tag name

    Returns Connection<T, TR>

  • connect Signals/Slots

    Returns

    Parameters

    • slot: SlotCallback<T, TR>
    • Optional tag: any

      Slots group tag name

    Returns Connection<T, TR>

  • Disconnect all connections from slot to this signals

    Parameters

    Returns void

  • Disconnect all tags

    Parameters

    • tag: any

    Returns void

  • delete all slots

    Returns void

  • Generate a signal to call all Slots

    Parameters

    • val: T

      Parameters passed to the slot

    • Optional combiner: Combiner<T, TR>

      a temporary combiner

    Returns void

Generated using TypeDoc