|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.bankframe.services.notification.Node
public class Node
This class encapsulates a nodes attributes. This class is made mutable via the getters/setters defined.
| Field Summary | |
|---|---|
static String |
DP_NAME
|
static String |
ID_KEY
|
static String |
IP_KEY
|
static String |
PORT_KEY
|
| Constructor Summary | |
|---|---|
Node()
Default constructor |
|
Node(DataPacket thisPacket)
This constructor is a convenient constructor allowing for the creation of a Node directly from a datapacket |
|
Node(String ID,
String IP,
String PORT)
Constructor |
|
| Method Summary | |
|---|---|
String |
getID()
This getter returns the ID attribute |
String |
getIP()
This getter returns the IP attribute |
String |
getPORT()
This getter returns the PORT attribute |
void |
setID(String ID)
This method sets the ID attribute |
void |
setIP(String IP)
This method sets the IP attribute |
void |
setPORT(String PORT)
This method sets the PORT attribute |
DataPacket |
toDataPacket()
Returns a datapacket representation of the node class |
String |
toString()
This method overwrites the behaviour of the java.lang.Object.toString() to return a String representation of the atttributes of the node class |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final String ID_KEY
public static final String IP_KEY
public static final String PORT_KEY
public static final String DP_NAME
| Constructor Detail |
|---|
public Node()
public Node(String ID,
String IP,
String PORT)
ID - StringIP - StringPORT - Stringpublic Node(DataPacket thisPacket)
thisPacket - DataPacket| Method Detail |
|---|
public String getID()
public String getIP()
public String getPORT()
public void setID(String ID)
ID - Stringpublic void setIP(String IP)
IP - Stringpublic void setPORT(String PORT)
PORT - Stringpublic String toString()
toString in class Objectpublic DataPacket toDataPacket()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||