### Question:
SortedRangeSet implements ValueSet { @Transient @Override public Object getSingleValue() { if (!isSingleValue()) { throw new IllegalStateException("SortedRangeSet does not have just a single value"); } if (nullAllowed && lowIndexedRanges.isEmpty()) { return null; } return lowIndexedRanges.values().iterator().next().getSingleValue(); } private  SortedRangeSet(ArrowType type, NavigableMap<ValueMarker, Range> lowIndexedRanges, boolean nullAllowed); static SortedRangeSet of(Range first, Range... rest); static SortedRangeSet of(boolean nullAllowed, Range first, Range... rest); static SortedRangeSet of(boolean nullAllowed, Range first, Collection<Range> rest); @JsonCreator static SortedRangeSet copyOf(
            @JsonProperty("type") ArrowType type,
            @JsonProperty("ranges") List<Range> ranges,
            @JsonProperty("nullAllowed") boolean nullAllowed
    ); @JsonProperty("nullAllowed") @Override boolean isNullAllowed(); @JsonProperty ArrowType getType(); @JsonProperty("ranges") List<Range> getOrderedRanges(); @Transient int getRangeCount(); @Transient @Override boolean isNone(); @Transient @Override boolean isAll(); @Transient @Override boolean isSingleValue(); @Transient @Override Object getSingleValue(); @Override boolean containsValue(Marker marker); @Override boolean containsValue(Object value); @Transient Range getSpan(); @Override Ranges getRanges(); @Override SortedRangeSet intersect(BlockAllocator allocator, ValueSet other); @Override SortedRangeSet union(BlockAllocator allocator, ValueSet other); @Override SortedRangeSet union(BlockAllocator allocator, Collection<ValueSet> valueSets); @Override SortedRangeSet complement(BlockAllocator allocator); @Override int hashCode(); @Override boolean equals(Object obj); @Override String toString(); static Builder newBuilder(ArrowType type, boolean nullAllowed); @Override void close();  }### Answer:
@Test public void testGetSingleValue() throws Exception { assertEquals(SortedRangeSet.of(allocator, BIGINT.getType(), 0L).getSingleValue(), 0L); try { SortedRangeSet.all(allocator, BIGINT.getType()).getSingleValue(); fail(); } catch (IllegalStateException e) { } }