Java(tm) Communications API
API Changes between EA3 and Beta 1
API Additions
1) CommPort now has a toString() method
API Changes
Name Changes:
getBaudrate() is now getBaudRate()
getFlowcontrolMode() is now getFlowControlMode()
setFlowcontrolMode is now setFlowControlMode()
- Converted all methods with
Rcv in the name to Receive
. i.e, in CommPort
-
disableRcvFraming() -> disableReceiveFraming()
-
disableRcvThreshold() -> disableReceiveThreshold()
-
disableRcvTimeout() -> disableReceiveTimeout()
-
enableRcvFraming() -> enableReceiveFraming()
-
enableRcvThreshold -> enableReceiveThreshold()
-
enableRcvTimeout() -> enableReceiveTimeout()
-
getRcvFramingByte() -> getReceiveFramingByte()
-
getRcvThreshold() -> getReceiveThreshold()
-
getRcvTimeout() -> getReceiveTimeout()
-
isRcvFramingEnabled() -> isReceiveFramingEnabled()
-
isRcvThresholdEnabled() -> isReceiveThresholdEnabled()
-
isRcvTimeoutEnabled() -> isReceiveTimeoutEnabled()
openPort() is now open()
closePort is now close().
FLOWCTRL has been changed to FLOWCONTROL.
i.e, in SerialPort
-
FLOWCTRL_NONE -> FLOWCONTROL_NONE
-
FLOWCTRL_RTSCTS_IN -> FLOWCONTROL_RTSCTS_IN
-
FLOWCTRL_RTSCTS_OUT -> FLOWCONTROL_RTS_CTS_OUT
-
FLOWCTRL_XONXOFF_IN -> FLOWCONTROL_XONXOFF_IN
-
FLOWCTRL_XONXOFF_OUT -> FLOWCONTROL_XONXOFF_OUT
DATA_AVAIL is now DATA_AVAILABLE in
SerialPortEvent class.
OUTBUF_EMPTY is now OUTPUT_BUFFER_EMPTY in
SerialPortEvent.
Exception Throwing:
setFlowControlMode() throws an
UnsupportedCommOperationException for unsupported modes.
SerialPort.addEventListener() and
ParallelPort.addEventListener() throw a
java.util.TooManyListenersException() if a second listener is
attempted to be added.
- CommPort's
enableReceiveTimeout(),
enableReceiveThreshold(), and enableReceiveFraming()
methods throw an UnsupportedCommOperationException if that
particular operation is not supported by the driver.
ParallelPort.setMode() throws an
UnsupportedCommOperationException if the mode is not supported by
the driver.
Copyright © 1998 Sun Microsystems, Inc.
All Rights Reserved.