Options
All
  • Public
  • Public/Protected
  • All
Menu

Class FlatMultiMap<Key, T>

Multiple-key Map based on sorted array.

author

Jeongho Nam - https://github.com/samchon

Type parameters

  • Key

  • T

Hierarchy

  • MultiTreeMap<Key, T, FlatMultiMap<Key, T>, FlatMultiMap.Iterator<Key, T>, FlatMultiMap.ReverseIterator<Key, T>>
    • FlatMultiMap

Implements

Index

Constructors

constructor

Methods

[Symbol.iterator]

  • [Symbol.iterator](): IterableIterator<Entry<Key, T>>

assign

  • assign<InputIterator>(first: InputIterator, last: InputIterator): void

begin

  • begin(): FlatMultiMap.Iterator<Key, T>

clear

  • clear(): void

count

  • count(key: Key): number

emplace

  • emplace(key: Key, val: T): FlatMultiMap.Iterator<Key, T>

emplace_hint

  • emplace_hint(hint: FlatMultiMap.Iterator<Key, T>, key: Key, val: T): FlatMultiMap.Iterator<Key, T>

empty

  • empty(): boolean

end

  • end(): FlatMultiMap.Iterator<Key, T>

equal_range

  • equal_range(key: Key): Pair<FlatMultiMap.Iterator<Key, T>, FlatMultiMap.Iterator<Key, T>>

erase

  • erase(key: Key): number
  • erase(it: FlatMultiMap.Iterator<Key, T>): FlatMultiMap.Iterator<Key, T>
  • erase(begin: FlatMultiMap.Iterator<Key, T>, end: FlatMultiMap.Iterator<Key, T>): FlatMultiMap.Iterator<Key, T>

find

  • find(key: Key): FlatMultiMap.Iterator<Key, T>

has

  • has(key: Key): boolean

insert

  • insert(pair: IPair<Key, T>): FlatMultiMap.Iterator<Key, T>
  • insert(hint: FlatMultiMap.Iterator<Key, T>, pair: IPair<Key, T>): FlatMultiMap.Iterator<Key, T>
  • insert<InputIterator>(first: InputIterator, last: InputIterator): void
  • Insert an element.

    Parameters

    • pair: IPair<Key, T>

      A tuple to be referenced for the insert.

    Returns FlatMultiMap.Iterator<Key, T>

    An iterator to the newly inserted element.

  • Insert an element with hint.

    Parameters

    • hint: FlatMultiMap.Iterator<Key, T>

      Hint for the position where the element can be inserted.

    • pair: IPair<Key, T>

      A tuple to be referenced for the insert.

    Returns FlatMultiMap.Iterator<Key, T>

    An iterator to the newly inserted element.

  • Insert range elements.

    Type parameters

    Parameters

    • first: InputIterator

      Input iterator of the first position.

    • last: InputIterator

      Input iteartor of the last position.

    Returns void

key_comp

  • key_comp(): Comparator<Key>

lower_bound

  • lower_bound(key: Key): FlatMultiMap.Iterator<Key, T>

merge

nth

  • nth(index: number): FlatMultiMap.Iterator<Key, T>

push

  • push(...items: IPair<Key, T>[]): number

rbegin

  • rbegin(): FlatMultiMap.ReverseIterator<Key, T>

rend

  • rend(): FlatMultiMap.ReverseIterator<Key, T>

size

  • size(): number

swap

toJSON

  • toJSON(): Array<Entry<Key, T>>

upper_bound

  • upper_bound(key: Key): FlatMultiMap.Iterator<Key, T>

value_comp

  • value_comp(): Comparator<IPair<Key, T>>

Generated using TypeDoc