public static final class SqlFragment.SourcePiece extends Object
length characters of a LITERAL's text, from textStart, read from one string literal token of the
analyzed source (Mantis 4851): where each sits there, so that what GSP analyzes inside the string reports
positions in the source. '' is one character of the text and two of the source; the token keeps its
quotes, a one-letter prefix such as N, and its line breaks.| Modifier and Type | Method and Description |
|---|---|
long[] |
fill(long[] lines,
long[] columns,
int base)
Writes the source line and column of each character of this piece into
lines and columns,
at index base + textStart + k for its k-th character; returns the position just past its last
character, the literal's closing quote, where a value concatenated after it is spliced in. |
static SqlFragment.SourcePiece |
of(TSourceToken token,
String decoded)
The piece of string literal token
token whose content decodes to decoded: null unless the
token is a single-quoted literal (with at most a one-letter prefix) whose content, '' read as one
quote, is exactly decoded. |
public static SqlFragment.SourcePiece of(TSourceToken token, String decoded)
token whose content decodes to decoded: null unless the
token is a single-quoted literal (with at most a one-letter prefix) whose content, '' read as one
quote, is exactly decoded.public long[] fill(long[] lines, long[] columns, int base)
lines and columns,
at index base + textStart + k for its k-th character; returns the position just past its last
character, the literal's closing quote, where a value concatenated after it is spliced in.