interface SortedSet.NonEmpty<T>
A non-empty type-invariant immutable Set of value type T. In the Set, there are no duplicate values. See the Set documentation and the SortedSet API documentation
Type parameters
Name | Description |
---|---|
T | the value type |
note
- The
SortedSet
keeps the inserted values in sorted order according to the context'scomp
Comp
instance.
example
const s1 = SortedSet.empty<string>()
const s2 = SortedSet.of('a', 'b', 'c')
Methods
max
Returns the maximum value of the SortedSet.
max
min
Returns the minimum value of the SortedSet.
min
stream
undocumented
stream
Definition
stream(options?: {
reversed?: boolean;
}):
Stream.NonEmpty
<T>;
Parameters
Name | Type | Description |
---|---|---|
options | { reversed?: boolean; } |