Span in the form of zero-based offsets
within the source. The "unit of measure" the offsets count depends on the
source type: for byte arrays or InputStreams, the offsets count
octets, but for Strings or java.io.Reader s the offsets count
UTF-16 code units.Warning
This interface should not be implemented or extended by code outside of this library.
As with all spans, positions lie between values, and when the start and finish positions are equal, the span is said to be empty.
To get one of these from a Span, use
asFacet(OffsetSpan.class) or one of
the helpers from Facets.
| Modifier and Type | Method and Description |
|---|---|
| public long | |
| public long |
| getFinishOffset | back to summary |
|---|---|
| public long getFinishOffset() Returns this span's finish position as a zero-based offset within the
source. In some cases, the finish position is implicit and this method
returns | |
| getStartOffset | back to summary |
|---|---|
| public long getStartOffset() Returns this span's start position as a zero-based offset within the source. | |