On this page

new LazySet(iterable?): void

Seeds the set with an optional iterable while preparing internal queues for deferred merges.

Attributes
Returns the number of items after applying any deferred merges.
Returns:
<SetIterator> < <T> >

Returns the default iterator over values after forcing pending merges.


add(item): void

Adds a single item immediately to the concrete backing set.


addAll(iterable): LazySet
Attributes
iterable:<LazySet>
< <T> > | <Iterable> < <T> , <any> , <any> >
Returns:<LazySet>
< <T> >

Queues another iterable or lazy set for later merging so large bulk adds can stay cheap until the set is read.


clear(): void
Returns:
{void}

Removes all items and clears every deferred merge queue.


delete(value): void

Deletes an item after first materializing any deferred additions that may contain it.


entries(): SetIterator
Returns:
<SetIterator> < <Tuple> < <T> , <T> >>

Returns the set's entry iterator and permanently switches future operations to eager merge mode to preserve iterator correctness.


forEach(callbackFn, thisArg): void
Attributes
callbackFn:<object>
thisArg:
{K}
Returns:
{void}

Iterates over every item after forcing pending merges and switching to eager mode for correctness during iteration.


has(item): void

Checks whether an item is present after applying any deferred merges.


keys(): SetIterator
Returns:
<SetIterator> < <T> >

Returns the key iterator, eagerly materializing pending merges first.


serialize(__namedParameters): void
Attributes
__namedParameters:<ObjectSerializerContext>
Returns:
{void}

Serializes the fully materialized set contents into webpack's object serialization stream.


values(): SetIterator
Returns:
<SetIterator> < <T> >

Returns the value iterator, eagerly materializing pending merges first.


Attributes
__namedParameters:<ObjectDeserializerContext>
Returns:<LazySet>
< <T> >

Restores a LazySet from serialized item data.