public void addRange(long offset, long rangeLen) {
		if (rangeLen <= 0) {
			throw new IllegalArgumentException();
		}
		Entry<Long, Long> lastEntry = offsetMap.lastEntry();
		if (lastEntry != null) {
			// try to merge sparse ranges
			long lastRangeOffset = lastEntry.getValue();
			if (offset == -1 && lastRangeOffset == -1) {
				length += rangeLen;
				return;
			}

			// try to merge this new range into the previous range
			long lastRangeLen = length - lastEntry.getKey();
			if (lastRangeOffset + lastRangeLen == offset) {
				length += rangeLen;
				return;
			}
		}
		offsetMap.put(length, offset);
		length += rangeLen;
	}
Adds a range to the current end of this instance.
<p>
If the new range immediately follows the previous range, the new range is merged
into the previous entry.

@param offset long byte offset in the delegate ByteProvider, -1 indicates a sparse
range with no storage
@param rangeLen long length of the range in the delegate ByteProvider
Ghidra/Features/Base/src/main/java/ghidra/app/util/bin/RangeMappedByteProvider.java