Class ImmutableRangeSet.Builder<C extends Comparable<? super C>>
java.lang.Object
cloud.opencode.base.collections.immutable.ImmutableRangeSet.Builder<C>
- Type Parameters:
C- endpoint type | 端点类型
- Enclosing class:
ImmutableRangeSet<C extends Comparable<? super C>>
Builder for
ImmutableRangeSet.
ImmutableRangeSet 的构建器。
Uses a TreeRangeSet internally for automatic range coalescing.
内部使用 TreeRangeSet 自动合并范围。
- Since:
- JDK 25, opencode-base-collections V1.0.3
- Author:
- Leon Soo www.LeonSoo.com
-
Method Summary
Modifier and TypeMethodDescriptionAdd a range to the builder.Add all ranges from another range set.build()Build the immutable range set.
-
Method Details
-
add
Add a range to the builder. 向构建器添加范围。- Parameters:
range- the range to add | 要添加的范围- Returns:
- this builder | 此构建器
-
addAll
Add all ranges from another range set. 从另一个范围集合添加所有范围。- Parameters:
other- the other range set | 另一个范围集合- Returns:
- this builder | 此构建器
-
build
Build the immutable range set. 构建不可变范围集合。- Returns:
- immutable range set | 不可变范围集合
-