Type Parameters

  • K

  • V

Hierarchy

  • Map<K, V>

    Hierarchy

    • EventEmittingMap

Constructors

  • Type Parameters

    Type Parameters

    • K

    • V

    Parameters

    • Optional entries: null | readonly (readonly [K, V])[]

    Returns EventEmittingMap<K, V>

  • Type Parameters

    Type Parameters

    • K

    • V

    Parameters

    • Optional iterable: null | Iterable<readonly [K, V]>

    Returns EventEmittingMap<K, V>

Properties

[toStringTag]: "EventEmittingMap" = 'EventEmittingMap'
listeners: { delete: ((...args: any[]) => void)[]; get: ((...args: any[]) => void)[]; has: ((...args: any[]) => void)[]; set: ((...args: any[]) => void)[] } = ...

Type declaration

  • delete: ((...args: any[]) => void)[]
  • get: ((...args: any[]) => void)[]
  • has: ((...args: any[]) => void)[]
  • set: ((...args: any[]) => void)[]

Methods

  • Returns an array listing the events for which the Map has registered listeners.

    Returns ("delete" | "get" | "has" | "set")[]

  • Parameters

    • event: "set"
    • callback: ((key: K, value: V) => void)
        • (key: K, value: V): void
        • Parameters

          • key: K
          • value: V

          Returns void

    Returns boolean

  • Parameters

    • event: "delete"
    • callback: ((key: K, result: boolean) => void)
        • (key: K, result: boolean): void
        • Parameters

          • key: K
          • result: boolean

          Returns void

    Returns boolean

  • Parameters

    • event: "has"
    • callback: ((key: K, result: boolean) => void)
        • (key: K, result: boolean): void
        • Parameters

          • key: K
          • result: boolean

          Returns void

    Returns boolean

  • Parameters

    • event: "get"
    • callback: ((key: K, result: undefined | V) => void)
        • (key: K, result: undefined | V): void
        • Parameters

          • key: K
          • result: undefined | V

          Returns void

    Returns boolean

Events

Generated using TypeDoc