Options
All
  • Public
  • Public/Protected
  • All
Menu

Class TreeMultiSet<Key>

Multiple-key Set based on Tree.

author

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

Type parameters

  • Key

Hierarchy

Implements

Index

Type aliases

Static Iterator

Iterator<Key>: Iterator<Key, false, TreeMultiSet<Key>>

Iterator of TreeMultiSet

Type parameters

  • Key

Static ReverseIterator

ReverseIterator<Key>: ReverseIterator<Key, false, TreeMultiSet<Key>>

Reverse iterator of TreeMultiSet

Type parameters

  • Key

Constructors

constructor

  • Default Constructor.

    Parameters

    • Optional comp: Comparator<Key>

      A binary function predicates x element would be placed before y. When returns true, then x precedes y. Note that, because equality is predicated by !comp(x, y) && !comp(y, x), the function must not cover the equality like <= or >=. It must exclude the equality like < or >. Default is less.

    Returns TreeMultiSet

  • Initializer Constructor.

    Parameters

    • items: Key[]

      Items to assign.

    • Optional comp: Comparator<Key>

      A binary function predicates x element would be placed before y. When returns true, then x precedes y. Note that, because equality is predicated by !comp(x, y) && !comp(y, x), the function must not cover the equality like <= or >=. It must exclude the equality like < or >. Default is less.

    Returns TreeMultiSet

  • Copy Constructor.

    Parameters

    Returns TreeMultiSet

  • Range Constructor.

    Parameters

    • first: Readonly<IForwardIterator<Key>>

      Input iterator of the first position.

    • last: Readonly<IForwardIterator<Key>>

      Input iterator of the last position.

    • Optional comp: Comparator<Key>

      A binary function predicates x element would be placed before y. When returns true, then x precedes y. Note that, because equality is predicated by !comp(x, y) && !comp(y, x), the function must not cover the equality like <= or >=. It must exclude the equality like < or >. Default is less.

    Returns TreeMultiSet

Methods

[Symbol.iterator]

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

assign

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

begin

clear

  • clear(): void

count

  • count(key: Key): number

empty

  • empty(): boolean

end

equal_range

erase

find

has

  • has(key: Key): boolean

insert

  • insert(key: Key): Iterator<Key>
  • insert(hint: Iterator<Key>, key: Key): Iterator<Key>
  • insert<InputIterator>(begin: InputIterator, end: InputIterator): void

key_comp

  • key_comp(): Comparator<Key>

lower_bound

merge

push

  • push(...items: Key[]): number

rbegin

rend

size

  • size(): number

swap

toJSON

  • toJSON(): Array<Key>

upper_bound

value_comp

  • value_comp(): Comparator<Key>

Generated using TypeDoc