protected class FormattingConfigBasedStream.Line
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
protected java.util.List<FormattingConfigBasedStream.LineEntry> |
entries |
protected java.lang.String |
indent |
protected int |
lastBreakableEntryIndex |
protected int |
leftover |
protected boolean |
startWithNL |
protected int |
totalLength |
| Modifier | Constructor and Description |
|---|---|
|
FormattingConfigBasedStream.Line() |
protected |
FormattingConfigBasedStream.Line(int leftover) |
protected |
FormattingConfigBasedStream.Line(java.util.List<FormattingConfigBasedStream.LineEntry> entries) |
protected |
FormattingConfigBasedStream.Line(java.util.List<FormattingConfigBasedStream.LineEntry> initialEntries,
int leftover) |
| Modifier and Type | Method and Description |
|---|---|
FormattingConfigBasedStream.Line |
add(FormattingConfigBasedStream.LineEntry lineEntry) |
protected void |
addSpacesToTotalLength(FormattingConfigBasedStream.LineEntry lineEntry,
boolean first) |
void |
flush() |
protected void |
flush(ITokenStream intoStream,
int endIndex) |
protected FormattingConfigBasedStream.Line |
flushLine() |
protected java.lang.String |
getIndentation(int indentation) |
Pair<AbstractRule,java.lang.String> |
getSpaces(FormattingConfigBasedStream.LineEntry entry,
boolean isLineStart) |
java.lang.String |
getSpacesStr(FormattingConfigBasedStream.LineEntry entry,
boolean isLineStart) |
java.lang.String |
toString() |
protected java.lang.String |
wrap(int lines,
java.lang.String indent) |
protected java.util.List<FormattingConfigBasedStream.LineEntry> entries
protected java.lang.String indent
protected int lastBreakableEntryIndex
protected int leftover
protected boolean startWithNL
protected int totalLength
public FormattingConfigBasedStream.Line()
protected FormattingConfigBasedStream.Line(int leftover)
protected FormattingConfigBasedStream.Line(java.util.List<FormattingConfigBasedStream.LineEntry> entries)
protected FormattingConfigBasedStream.Line(java.util.List<FormattingConfigBasedStream.LineEntry> initialEntries, int leftover)
public FormattingConfigBasedStream.Line add(FormattingConfigBasedStream.LineEntry lineEntry) throws java.io.IOException
java.io.IOExceptionprotected void addSpacesToTotalLength(FormattingConfigBasedStream.LineEntry lineEntry, boolean first)
public void flush()
throws java.io.IOException
java.io.IOExceptionprotected void flush(ITokenStream intoStream, int endIndex) throws java.io.IOException
endIndex - the index of the last entry to flush, exclusive.java.io.IOExceptionprotected FormattingConfigBasedStream.Line flushLine() throws java.io.IOException
java.io.IOExceptionprotected java.lang.String getIndentation(int indentation)
public Pair<AbstractRule,java.lang.String> getSpaces(FormattingConfigBasedStream.LineEntry entry, boolean isLineStart)
public java.lang.String getSpacesStr(FormattingConfigBasedStream.LineEntry entry, boolean isLineStart)
public java.lang.String toString()
toString in class java.lang.Objectprotected java.lang.String wrap(int lines,
java.lang.String indent)