public class IndentingWriter
extends java.io.Writer
| Modifier and Type | Field and Description |
|---|---|
protected char[] |
buffer |
protected int |
indentLevel |
protected java.io.Writer |
writer |
| Constructor and Description |
|---|
IndentingWriter(java.io.Writer writer) |
| Modifier and Type | Method and Description |
|---|---|
java.io.Writer |
append(char c) |
java.io.Writer |
append(java.lang.CharSequence charSequence) |
java.io.Writer |
append(java.lang.CharSequence charSequence,
int start,
int len) |
void |
close() |
void |
deindent(int indentAmount) |
void |
flush() |
void |
indent(int indentAmount) |
void |
printSignedIntAsDec(int value) |
void |
printSignedLongAsDec(long value) |
void |
printUnsignedIntAsDec(int value) |
void |
printUnsignedLongAsHex(long value) |
void |
write(char[] chars) |
void |
write(char[] chars,
int start,
int len) |
void |
write(int chr) |
void |
write(java.lang.String s) |
void |
write(java.lang.String str,
int start,
int len) |
protected void |
writeIndent() |
protected final java.io.Writer writer
protected final char[] buffer
protected int indentLevel
protected void writeIndent()
throws java.io.IOException
java.io.IOExceptionpublic void write(int chr)
throws java.io.IOException
write in class java.io.Writerjava.io.IOExceptionpublic void write(char[] chars)
throws java.io.IOException
write in class java.io.Writerjava.io.IOExceptionpublic void write(char[] chars,
int start,
int len)
throws java.io.IOException
write in class java.io.Writerjava.io.IOExceptionpublic void write(java.lang.String s)
throws java.io.IOException
write in class java.io.Writerjava.io.IOExceptionpublic void write(java.lang.String str,
int start,
int len)
throws java.io.IOException
write in class java.io.Writerjava.io.IOExceptionpublic java.io.Writer append(java.lang.CharSequence charSequence)
throws java.io.IOException
append in interface java.lang.Appendableappend in class java.io.Writerjava.io.IOExceptionpublic java.io.Writer append(java.lang.CharSequence charSequence,
int start,
int len)
throws java.io.IOException
append in interface java.lang.Appendableappend in class java.io.Writerjava.io.IOExceptionpublic java.io.Writer append(char c)
throws java.io.IOException
append in interface java.lang.Appendableappend in class java.io.Writerjava.io.IOExceptionpublic void flush()
throws java.io.IOException
flush in interface java.io.Flushableflush in class java.io.Writerjava.io.IOExceptionpublic void close()
throws java.io.IOException
close in interface java.io.Closeableclose in interface java.lang.AutoCloseableclose in class java.io.Writerjava.io.IOExceptionpublic void indent(int indentAmount)
public void deindent(int indentAmount)
public void printUnsignedLongAsHex(long value)
throws java.io.IOException
java.io.IOExceptionpublic void printSignedLongAsDec(long value)
throws java.io.IOException
java.io.IOExceptionpublic void printSignedIntAsDec(int value)
throws java.io.IOException
java.io.IOExceptionpublic void printUnsignedIntAsDec(int value)
throws java.io.IOException
java.io.IOException