java.lang.Comparable<NodeId>@Public @Stable public abstract class NodeId extends java.lang.Object implements java.lang.Comparable<NodeId>
NodeId is the unique identifier for a node.
It includes the hostname and port to uniquely
identify the node. Thus, it is unique across restarts of any
NodeManager.
| Constructor | Description |
|---|---|
NodeId() |
| Modifier and Type | Method | Description |
|---|---|---|
protected abstract void |
build() |
|
int |
compareTo(NodeId other) |
|
boolean |
equals(java.lang.Object obj) |
|
static NodeId |
fromString(java.lang.String nodeIdStr) |
|
abstract java.lang.String |
getHost() |
Get the hostname of the node.
|
abstract int |
getPort() |
Get the port for communicating with the node.
|
int |
hashCode() |
|
static NodeId |
newInstance(java.lang.String host,
int port) |
|
protected abstract void |
setHost(java.lang.String host) |
|
protected abstract void |
setPort(int port) |
|
java.lang.String |
toString() |
@Public @Stable public static NodeId newInstance(java.lang.String host, int port)
@Public @Stable public abstract java.lang.String getHost()
@Private @Unstable protected abstract void setHost(java.lang.String host)
@Public @Stable public abstract int getPort()
@Private @Unstable protected abstract void setPort(int port)
public java.lang.String toString()
toString in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int compareTo(NodeId other)
compareTo in interface java.lang.Comparable<NodeId>@Public @Stable public static NodeId fromString(java.lang.String nodeIdStr)
protected abstract void build()
Copyright © 2008–2025 Apache Software Foundation. All rights reserved.