interface VariantSetBase.NonEmpty<T,Tp>
undocumented
Extends: Streamable.NonEmpty<T>
, VariantSetBase<T,Tp>
Implemented by: RSetBase.NonEmpty<T,Tp>
, VariantSet.NonEmpty<T>
Type parameters
Name | Constraints | Default | Description |
---|---|---|---|
T | undocumented | ||
Tp | VariantSetBase.Types | VariantSetBase.Types | undocumented |
Properties
isEmpty
Returns false since this collection is known to be non-empty
isEmpty
size
Returns the number of values in the collection.
size
Methods
[Symbol.iterator]
Returns a FastIterator
instance used to iterate over the values of this Iterable
.
[Symbol.iterator]
FastIterator
instance used to iterate over the values of this Iterable
.asNormal
Returns this collection typed as a 'possibly empty' collection.
asNormal
assumeNonEmpty
Returns a self reference since this collection is known to be non-empty.
assumeNonEmpty
difference
Returns a collection where each value of given other
StreamSource
is removed from this collection.
difference
other
StreamSource
is removed from this collection.filter
Returns a collection containing only those entries that satisfy given pred
predicate.
filter
pred
predicate.forEach
Performs given function f
for each value of the collection, using given state
as initial traversal state.
forEach
f
for each value of the collection, using given state
as initial traversal state.has
Returns true if given value
is in the collection.
has
value
is in the collection.intersect
Returns a collection containing values that are both in this collection, and in the given other
StreamSource
.
intersect
other
StreamSource
.nonEmpty
Returns true since this collection is know to be non-empty
nonEmpty
remove
Returns the collection with given value
removed.
remove
value
removed.removeAll
Returns the collection with all values in the given values
StreamSource
removed.
removeAll
values
StreamSource
removed.stream
Returns a non-empty Stream containing all values of this collection.
stream
toArray
Returns a non-empty array containing all values in this collection.
toArray
toJSON
Returns a JSON representation of this collection.
toJSON
toString
Returns a string representation of this collection.
toString