class SortedRangeSet implements ValueSet {

    @Override
    public SortedRangeSet union(BlockAllocator allocator, ValueSet other)
    {
        boolean unionNullAllowed = this.isNullAllowed() || other.isNullAllowed();
        SortedRangeSet otherRangeSet = checkCompatibility(other);
        return new Builder(type, unionNullAllowed)
                .addAll(this.getOrderedRanges())
                .addAll(otherRangeSet.getOrderedRanges())
                .build();
    }

    private  SortedRangeSet(ArrowType type, NavigableMap<ValueMarker, Range> lowIndexedRanges, boolean nullAllowed);

}