Class VcsEvent<T>

Type Parameters

  • T

Hierarchy

  • VcsEvent

Accessors

  • get numberOfListeners(): number
  • The number of listeners

    Returns number

Constructors

Methods

  • Adds an event listener. An event listener can only be added once. A listener added multiple times will only be called once.

    Parameters

    • listener: Listener<T>

    Returns (() => void)

    • remove callback. call this function to remove the listener
      • (): void
      • Adds an event listener. An event listener can only be added once. A listener added multiple times will only be called once.

        Returns void

        • remove callback. call this function to remove the listener
  • Parameters

    • event: T

    Returns Promise<void>

  • Raise the event, calling all listeners, if a listener is removed in between calling listeners, the listener is not called.

    Parameters

    • event: T

    Returns void

  • Removes the provided listener

    Parameters

    • listener: Listener<T>

    Returns boolean

    • whether a listener was removed

Properties

_listeners: Set<Listener<T>> = ...

Generated using TypeDoc