public interface TextSpan
Span
in the form of one-based
line and column numbers within the source text stream.
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
(TextSpan.class)
or one of
the helpers from Spans
.
Modifier and Type | Method and Description |
---|---|
long |
getFinishColumn()
Returns the column number of this span's finish position, counting from
one.
|
long |
getFinishLine()
Returns the line number of this span's finish position, counting from
one.
|
long |
getStartColumn()
Returns the column number of this span's start position, counting from
one.
|
long |
getStartLine()
Returns the line number of this span's start position, counting from
one.
|
long getStartLine()
long getStartColumn()
long getFinishLine()
-1
. That's since in general (notably for containers) the
finish offset can't be determined without significant effort to parse
to the end of the value.long getFinishColumn()
-1
. That's since in general (notably for containers) the
finish offset can't be determined without significant effort to parse
to the end of the value.