Set

Set, designed to replace std::set usage. O(lg(n)) insertion, removal, and search time. Set is designed to operate even without initialization through makeSet.

Constructors

this
this(int dummy)
Undocumented in source.

Destructor

~this
~this()
Undocumented in source.

Postblit

this(this)
this(this)
Undocumented in source.

Members

Aliases

opSlice
alias opSlice = byKey
Undocumented in source.

Functions

byKey
auto byKey()

Fetch a forward range on all keys.

clearContents
void clearContents()

Removes all elements from the set.

contains
bool contains(K key)
empty
bool empty()
insert
bool insert(K key)

Insert an element in the container. If allowDuplicates is false, this can fail and return false if the already contains an element with equivalent key.

length
size_t length()
opBinaryRight
bool opBinaryRight(K key)
opIndex
bool opIndex(K key)
remove
bool remove(K key)

Removes an element from the container.

Meta