|
comm API Version 2.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.util.EventObject
javax.comm.SerialPortEvent
A serial port event.
SerialPort
,
SerialPortEventListener
,
EventObject
,
Serialized FormField Summary | |
static int |
BI
Break interrupt. |
static int |
CD
Carrier detect. |
static int |
CTS
Clear to send. |
static int |
DATA_AVAILABLE
Data available at the serial port. |
static int |
DSR
Data set ready. |
int |
eventType
Deprecated. Replaced by getEventType() method. |
static int |
FE
Framing error. |
static int |
OE
Overrun error. |
static int |
OUTPUT_BUFFER_EMPTY
Output buffer is empty. |
static int |
PE
Parity error. |
static int |
RI
Ring indicator. |
Fields inherited from class java.util.EventObject |
source |
Constructor Summary | |
SerialPortEvent(SerialPort srcport,
int eventtype,
boolean oldvalue,
boolean newvalue)
Constructs a SerialPortEvent
with the specified serial port, event type, old and new values.
|
Method Summary | |
int |
getEventType()
Gets the type of this event. |
boolean |
getNewValue()
Gets the new value of the state change that caused the SerialPortEvent to be propagated.
|
boolean |
getOldValue()
Gets the old value of the state change that caused the SerialPortEvent to be propagated.
|
Methods inherited from class java.util.EventObject |
getSource, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public int eventType
getEventType()
method.
public static final int DATA_AVAILABLE
public static final int OUTPUT_BUFFER_EMPTY
public static final int CTS
public static final int DSR
public static final int RI
public static final int CD
public static final int OE
public static final int PE
public static final int FE
public static final int BI
Constructor Detail |
public SerialPortEvent(SerialPort srcport, int eventtype, boolean oldvalue, boolean newvalue)
SerialPortEvent
with the specified serial port, event type, old and new values.
Application programs should not directly create
SerialPortEvent
objects.
srcport
- source seriell porteventtype
- event typeoldvalue
- old valuenewvalue
- new valueMethod Detail |
public int getEventType()
BI
, CD
, CTS
,
DATA_AVAILABLE
, DSR
, FE
,
OE
, OUTPUT_BUFFER_EMPTY
, PE
or RI
.public boolean getNewValue()
SerialPortEvent
to be propagated.
For example, when the CD bit changes, newValue
reflects the new value of the CD bit.
true
if set.public boolean getOldValue()
SerialPortEvent
to be propagated.
For example, when the CD bit changes, oldValue
reflects the old value of the CD bit.
true
if set.
|
comm API Version 2.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |