|
DCT Lightfoot v3 API specification | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--java.io.OutputStream
|
+--com.dctl.j2me.io.SwitchableOutputStream
A switchable output stream can be used to dynamically reconfigure output streams at runtime without changing all the objects using the stream. This is ideally suited for debug streams, but can support other streams
| Constructor Summary | |
SwitchableOutputStream()
|
|
| Method Summary | |
void |
close()
Close the stream. |
void |
flush()
Flush the stream. |
void |
lock()
Lock the stream. |
void |
setStream(OutputStream out)
Set the stream to use |
void |
unlock()
Unlock the stream. |
void |
write(byte[] buf)
Write an array of bytes to the stream |
void |
write(byte[] buf,
int off,
int len)
Write an array of bytes to the stream |
void |
write(int b)
Write a byte to the stream |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public SwitchableOutputStream()
| Method Detail |
public void setStream(OutputStream out)
out - The stream to usepublic void lock()
lock in interface Lockablepublic void unlock()
unlock in interface Lockable
public void close()
throws IOException
close in class OutputStreamIOException - if there is an IO error
public void flush()
throws IOException
flush in class OutputStreamIOException - if there is an IO error
public void write(byte[] buf)
throws IOException
write in class OutputStreambuf - The buffer to write
IOException - if there is an IO error
public void write(byte[] buf,
int off,
int len)
throws IOException
write in interface Writablewrite in class OutputStreambuf - The buffer to writeoff - The offset in the bufferlen - The length in the buffer
IOException - if there is an IO error
public void write(int b)
throws IOException
write in interface Writablewrite in class OutputStreamb - The byte to write
IOException - if there is an IO error
|
DCT Lightfoot v3 API specification | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||