Package com.logicaldoc.util.io
Class StringOutputStream
- java.lang.Object
-
- java.io.OutputStream
-
- com.logicaldoc.util.io.StringOutputStream
-
- All Implemented Interfaces:
Closeable
,Flushable
,AutoCloseable
public class StringOutputStream extends OutputStream
An output stram that writes into a string- Since:
- 8.6.1
- Author:
- Marco Meschieri - LogicalDOC
-
-
Constructor Summary
Constructors Constructor Description StringOutputStream()
StringOutputStream(StringBuffer sb)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
void
flush()
String
getData()
void
write(byte b)
void
write(byte[] b)
void
write(int i)
-
Methods inherited from class java.io.OutputStream
nullOutputStream, write
-
-
-
-
Constructor Detail
-
StringOutputStream
public StringOutputStream()
-
StringOutputStream
public StringOutputStream(StringBuffer sb)
-
-
Method Detail
-
close
public void close() throws IOException
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Overrides:
close
in classOutputStream
- Throws:
IOException
-
flush
public void flush() throws IOException
- Specified by:
flush
in interfaceFlushable
- Overrides:
flush
in classOutputStream
- Throws:
IOException
-
write
public void write(byte[] b) throws IOException
- Overrides:
write
in classOutputStream
- Throws:
IOException
-
write
public void write(byte b) throws IOException
- Throws:
IOException
-
write
public void write(int i) throws IOException
- Specified by:
write
in classOutputStream
- Throws:
IOException
-
getData
public String getData()
-
-