All Packages Class Hierarchy This Package Previous Next Index
CommPortOwnership event
of type PORT_OWNED will be propagated.
When a port is closed, a CommPortOwnership event
of type PORT_UNOWNED will be propagated.
Multiple applications that are seeking ownership of a communications port can resolve their differences as follows:
open and takes ownership of port.
open sometime later.
open,
CommPortIdentifier will propagate a CommPortOwnership
event with the event type PORT_OWNERSHIP_REQUESTED.
close from within the
event callback.
CommPortIdentifier checks
to see if ownership was given up, and if so, turns over ownership
of the port to XYZapp by returning success from open.
close is called from within
a CommPortOwnership event callback,
a new CommPortOwnership event will
not be generated.
CommPortIdentifier.open.
CommPort.close.
CommPortOwnership event.
public static final int PORT_OWNED
CommPortIdentifier.open.
public static final int PORT_UNOWNED
CommPort.close.
public static final int PORT_OWNERSHIP_REQUESTED
CommPort.close during the processing
of this event and thereby give up ownership of the port.
public abstract void ownershipChange(int type)
CommPortOwnership event.
This method will be called with the type set to one of
the variables PORT_OWNED, PORT_UNOWNED,
or PORT_OWNERSHIP_REQUESTED.
All Packages Class Hierarchy This Package Previous Next Index