public final class NodeInfo
extends java.lang.Object
implements java.io.Serializable
WARNING: this class is not yet done. At a minimum, port information will need to be added to this class for each IP address. Otherwise this information is really of no use for making connections. Likewise, it is probable that a list of queues would be useful to allow routing decisions to be made. Even the above referenced data does not easily provide for mapping an entire network from a single location as is the concept behind the address server (which is the primary user of this class). For this reason, this class may be removed or changed in the future.
Modifier and Type | Field and Description |
---|---|
private int |
address
Node address.
|
private java.net.InetAddress[] |
ipList
List of internet addresses assigned to node.
|
private java.lang.String |
name
Node name.
|
Constructor and Description |
---|
NodeInfo()
Constructs an empty
NodeInfo instance. |
NodeInfo(int address)
Constructs an instance of
NodeInfo with assigned node
address. |
NodeInfo(int address,
java.lang.String name,
java.net.InetAddress[] ipList)
Constructs a completely filled instance of
NodeInfo . |
NodeInfo(java.lang.String name)
Constructs an instance of
NodeInfo with assigned node
name. |
Modifier and Type | Method and Description |
---|---|
int |
getAddress()
Provides access to the node address.
|
java.net.InetAddress[] |
getIpList()
Provides access to list of internet protocol addresses assigned to node.
|
java.lang.String |
getName()
Provides access to the node name.
|
void |
setAddress(int address)
Assign new node address.
|
void |
setIpList(java.net.InetAddress[] ipList)
Assign new list of internet addresses.
|
void |
setName(java.lang.String name)
Assign new node name.
|
private int address
private java.net.InetAddress[] ipList
private java.lang.String name
public NodeInfo()
NodeInfo
instance.public NodeInfo(int address)
NodeInfo
with assigned node
address.address
- Node address.public NodeInfo(java.lang.String name)
NodeInfo
with assigned node
name.name
- Node name.public NodeInfo(int address, java.lang.String name, java.net.InetAddress[] ipList)
NodeInfo
.address
- Node address.name
- Node name.ipList
- List of internet protocol addresses.public int getAddress()
public void setAddress(int address)
address
- Node address.public java.lang.String getName()
public void setName(java.lang.String name)
name
- Node name.public java.net.InetAddress[] getIpList()
public void setIpList(java.net.InetAddress[] ipList)
ipList
- List of internet addresses.