Package com.igormaznitsa.jcp.utils
Class ResetablePrinter
- java.lang.Object
-
- com.igormaznitsa.jcp.utils.ResetablePrinter
-
public class ResetablePrinter extends java.lang.Object
The class implements a resetable char printer
-
-
Field Summary
Fields Modifier and Type Field Description private java.io.CharArrayWriter
outStream
-
Constructor Summary
Constructors Constructor Description ResetablePrinter(int initialCapacity)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getSize()
boolean
isEmpty()
void
print(java.lang.String text)
void
println(java.lang.String text)
void
reset()
void
writeBufferTo(java.io.Writer writer)
-
-
-
Method Detail
-
isEmpty
public boolean isEmpty()
-
writeBufferTo
public void writeBufferTo(java.io.Writer writer) throws java.io.IOException
- Throws:
java.io.IOException
-
getSize
public int getSize()
-
reset
public void reset()
-
print
public void print(java.lang.String text) throws java.io.IOException
- Throws:
java.io.IOException
-
println
public void println(java.lang.String text) throws java.io.IOException
- Throws:
java.io.IOException
-
-