public class OutputStreamDemux extends ByteArrayOutputStream
| Modifier and Type | Class and Description |
|---|---|
protected static class |
OutputStreamDemux.OutputType |
| Modifier and Type | Field and Description |
|---|---|
private Map<String,Console> |
consoleMap |
private Map<String,Interpreter> |
interpreterMap |
private Map<String,ByteArrayOutputStream> |
streamMap |
private OutputStreamDemux.OutputType |
type |
buf, count| Constructor and Description |
|---|
OutputStreamDemux() |
| Modifier and Type | Method and Description |
|---|---|
void |
addStream(Console console,
Interpreter interpreter,
OutputStreamDemux.OutputType type) |
void |
close() |
void |
flush() |
private static String |
id() |
void |
reset() |
int |
size() |
byte[] |
toByteArray() |
String |
toString() |
String |
toString(int hibyte)
Deprecated.
|
String |
toString(String charsetName) |
void |
write(byte[] b) |
void |
write(byte[] b,
int off,
int len) |
void |
write(int b) |
void |
writeTo(OutputStream out) |
private OutputStreamDemux.OutputType type
private final Map<String,ByteArrayOutputStream> streamMap
private final Map<String,Interpreter> interpreterMap
private final Map<String,Console> consoleMap
public OutputStreamDemux()
public void addStream(Console console, Interpreter interpreter, OutputStreamDemux.OutputType type)
public void close() throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class ByteArrayOutputStreamIOExceptionpublic void flush() throws IOException
flush in interface Flushableflush in class OutputStreamIOExceptionpublic void write(byte[] b) throws IOException
write in class OutputStreamIOExceptionpublic void write(byte[] b, int off, int len)
write in class ByteArrayOutputStreampublic void write(int b)
write in class ByteArrayOutputStreampublic void reset()
reset in class ByteArrayOutputStreampublic int size()
size in class ByteArrayOutputStreampublic byte[] toByteArray()
toByteArray in class ByteArrayOutputStream@Deprecated public String toString(int hibyte)
toString in class ByteArrayOutputStreampublic String toString(String charsetName) throws UnsupportedEncodingException
toString in class ByteArrayOutputStreamUnsupportedEncodingExceptionpublic void writeTo(OutputStream out) throws IOException
writeTo in class ByteArrayOutputStreamIOExceptionpublic String toString()
toString in class ByteArrayOutputStream