rx-datatable API
    Preparing search index...

    Interface IMap<K, V>

    An interface compatible with ES6 Map and BTree. This interface does not describe the complete interface of either class, but merely the common interface shared by both.

    interface IMap<K = any, V = any> {
        size: number;
        clear(): void;
        delete(key: K): boolean;
        entries(): IterableIterator<[K, V]>;
        forEach(
            callbackFn: (v: V, k: K, map: IMapSource<K, V>) => void,
            thisArg?: any,
        ): void;
        get(key: K): V | undefined;
        has(key: K): boolean;
        keys(): IterableIterator<K>;
        set(key: K, value: V): any;
        values(): IterableIterator<V>;
    }

    Type Parameters

    • K = any
    • V = any

    Hierarchy (View Summary)

    Index
    size: number

    Returns the number of key/value pairs in the map object.

    • Returns true if an element in the map object existed and has been removed, or false if the element did not exist.

      Parameters

      • key: K

      Returns boolean

    • Returns an iterator that provides all key-value pairs from the collection (as arrays of length 2).

      Returns IterableIterator<[K, V]>

    • Calls callbackFn once for each key-value pair present in the map object. The ES6 Map class sends the value to the callback before the key, so this interface must do likewise.

      Parameters

      • callbackFn: (v: V, k: K, map: IMapSource<K, V>) => void
      • OptionalthisArg: any

      Returns void

    • Returns the value associated to the key, or undefined if there is none.

      Parameters

      • key: K

      Returns V | undefined

    • Returns a boolean asserting whether the key exists in the map object or not.

      Parameters

      • key: K

      Returns boolean

    • Sets the value for the key in the map object (the return value is boolean in BTree but Map returns the Map itself.)

      Parameters

      • key: K
      • value: V

      Returns any