|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.io.OutputStream
Serialio.SerOutputStream
Create an output stream on the serial port object.
| Field Summary | |
protected SerialPort |
sp
|
| Constructor Summary | |
SerOutputStream(SerialPort sp)
Create a serial port output stream. |
|
| Method Summary | |
void |
close()
Close the port. |
void |
flush()
Causes any buffered data on the output stream to be written. |
void |
flushAbort()
Aborts flush. |
int |
getTxBlockSize()
|
boolean |
getWriteDrain()
|
int |
getWriteTimeout()
|
void |
setTxBlockSize(int size)
Sets the block size used to send data. |
void |
setWriteDrain(boolean onOff)
Set txDrain mode for write(). |
void |
setWriteTimeout(int tmo)
Aborts flush based on timeout. |
void |
write(byte[] b)
Writes the data on the output stream. |
void |
write(byte[] b,
int off,
int len)
Writes the data on the output stream. |
void |
write(int b)
Writes the byte on the output stream |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected SerialPort sp
| Constructor Detail |
public SerOutputStream(SerialPort sp)
throws java.io.IOException
sp - a valid SerialPort object| Method Detail |
public void write(int b)
throws java.io.IOException
b - the data byte
java.io.IOException - if an error occurs.
public void write(byte[] b)
throws java.io.IOException
b - the byte array of data
java.io.IOException - if an I/O error occurs.
public void write(byte[] b,
int off,
int len)
throws java.io.IOException
b - the byte array buffer where data will be put when readoff - the offset in the buffer where data will be putlen - the length of data requested to be put in the buffer
java.io.IOException - if an error occurs.
public void flush()
throws java.io.IOException
java.io.IOException - if an error occurs.public void setWriteDrain(boolean onOff)
public boolean getWriteDrain()
public void flushAbort()
public void close()
throws java.io.IOException
java.io.IOException
public void setWriteTimeout(int tmo)
throws java.io.IOException
java.io.IOExceptionpublic int getWriteTimeout()
public void setTxBlockSize(int size)
public int getTxBlockSize()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||