rx-datatable API
    Preparing search index...

    Interface ISortedSet<K>

    An interface for a set of keys (the combination of ISortedSetSource and ISetSink)

    interface ISortedSet<K = any> {
        size: number;
        add(key: K): any;
        clear(): void;
        delete(key: K): boolean;
        forRange(
            low: K,
            high: K,
            includeHigh: boolean,
            onFound?: (k: K, v: any, counter: number) => void,
            initialCounter?: number,
        ): number;
        has(key: K): boolean;
        keys(firstKey?: K): IterableIterator<K>;
        maxKey(): K | undefined;
        minKey(): K | undefined;
        nextHigherKey(key?: K): K | undefined;
        nextLowerKey(key?: K): K | undefined;
    }

    Type Parameters

    • K = any

    Hierarchy (View Summary)

    Index
    size: number

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

    • Adds the specified item to the set, if it was not in the set already.

      Parameters

      • key: K

      Returns any

    • 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

    • Calls callback on the specified range of keys, in ascending order by key.

      Parameters

      • low: K

        The first key scanned will be greater than or equal to low.

      • high: K

        Scanning stops when a key larger than this is reached.

      • includeHigh: boolean

        If the high key is present in the map, onFound is called for that final pair if and only if this parameter is true.

      • OptionalonFound: (k: K, v: any, counter: number) => void

        A function that is called for each key pair. Because this is a subinterface of ISortedMapSource, if there is a value associated with the key, it is passed as the second parameter.

      • OptionalinitialCounter: number

        Initial third argument of onFound. This value increases by one each time onFound is called. Default: 0

      Returns number

      Number of pairs found and the number of times onFound was called.

    • Returns a new iterator for iterating the keys of each pair in ascending order.

      Parameters

      • OptionalfirstKey: K

        Minimum key to include in the output.

      Returns IterableIterator<K>

    • Returns the next key larger than the specified key (or undefined if there is none). Also, nextHigherKey(undefined) returns the lowest key.

      Parameters

      • Optionalkey: K

      Returns K | undefined

    • Returns the next key smaller than the specified key (or undefined if there is none). Also, nextLowerKey(undefined) returns the highest key.

      Parameters

      • Optionalkey: K

      Returns K | undefined