parse Printf Term
public int parsePrintfTerm(MessageBuilder<? extends Object> builder, int index, String message, int termStart, int specStart, int formatStart)
Parses a single printf-like term from a log message into a message template builder.
A simple example of an implicit parameter (the argument index is not specified):
message: "Hello %s World"
termStart: 6 ───┚╿╿
specStart: 7 ────┤│
formatStart: 7 ──╯│
return: 8 ────────╯
Content copied to clipboard
specStart == formatStart. A complex example with an explicit index:
message: "Hello %2$10d World"
termStart: 6 ───┚ ╿ ╿╿
specStart: 9 ──────╯ ││
formatStart: 11 ─────╯│
return: 12 ───────────╯
Content copied to clipboard
Return
the index after the last character of the term.
Parameters
builder
the message template builder.
index
the zero-based argument index for the parameter.
message
the complete log message string.
term Start
the index of the initial '%' character that starts the term.
spec Start
the index of the first format specification character (after any optional index specification).
format Start
the index of the (first) format character in the term.