public class CommPortIdentifier extends Object
| Modifier and Type | Class and Description |
|---|---|
class |
CommPortIdentifier.SerialPortImpl |
| Modifier and Type | Field and Description |
|---|---|
static int |
PORT_PARALLEL |
static int |
PORT_SERIAL |
| Constructor and Description |
|---|
CommPortIdentifier(String name,
CommPort port,
int type,
CommDriver driver) |
| Modifier and Type | Method and Description |
|---|---|
static void |
addPortName(String portName,
int portType,
CommDriver driver) |
void |
addPortOwnershipListener(CommPortOwnershipListener listener) |
String |
getCurrentOwner() |
String |
getName() |
static CommPortIdentifier |
getPortIdentifier(CommPort port) |
static CommPortIdentifier |
getPortIdentifier(String portName) |
static Enumeration |
getPortIdentifiers() |
int |
getPortType() |
boolean |
isCurrentlyOwned() |
CommPort |
open(FileDescriptor fd) |
CommPort |
open(String appname,
int timeout) |
void |
removePortOwnershipListener(CommPortOwnershipListener listener) |
public static final int PORT_PARALLEL
public static final int PORT_SERIAL
public CommPortIdentifier(String name, CommPort port, int type, CommDriver driver)
public static Enumeration getPortIdentifiers()
public static CommPortIdentifier getPortIdentifier(String portName) throws NoSuchPortException
NoSuchPortExceptionpublic static CommPortIdentifier getPortIdentifier(CommPort port) throws NoSuchPortException
NoSuchPortExceptionpublic static void addPortName(String portName, int portType, CommDriver driver)
public CommPort open(String appname, int timeout) throws PortInUseException
PortInUseExceptionpublic CommPort open(FileDescriptor fd) throws UnsupportedCommOperationException
public String getName()
public int getPortType()
public String getCurrentOwner()
public boolean isCurrentlyOwned()
public void addPortOwnershipListener(CommPortOwnershipListener listener)
public void removePortOwnershipListener(CommPortOwnershipListener listener)
Copyright © 2015. All rights reserved.