public class Node
extends java.lang.Object
Constructor | Description |
---|---|
Node(int id,
java.lang.String host,
int port) |
|
Node(int id,
java.lang.String host,
int port,
java.lang.String rack) |
Modifier and Type | Method | Description |
---|---|---|
boolean |
equals(java.lang.Object obj) |
|
int |
hashCode() |
|
boolean |
hasRack() |
True if this node has a defined rack
|
java.lang.String |
host() |
The host name for this node
|
int |
id() |
The node id of this node
|
java.lang.String |
idString() |
String representation of the node id.
|
boolean |
isEmpty() |
Check whether this node is empty, which may be the case if noNode() is used as a placeholder
in a response payload with an error.
|
static Node |
noNode() |
|
int |
port() |
The port for this node
|
java.lang.String |
rack() |
The rack for this node
|
java.lang.String |
toString() |
public Node(int id, java.lang.String host, int port)
public Node(int id, java.lang.String host, int port, java.lang.String rack)
public static Node noNode()
public boolean isEmpty()
public int id()
public java.lang.String idString()
public java.lang.String host()
public int port()
public boolean hasRack()
public java.lang.String rack()
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object