Package io.vertx.ext.consul
Class Node
- java.lang.Object
-
- io.vertx.ext.consul.Node
-
public class Node extends Object
- Author:
- Ruslan Sennov
-
-
Constructor Summary
Constructors Constructor Description Node()
Default constructorNode(JsonObject json)
Constructor from JSONNode(Node other)
Copy constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object o)
String
getAddress()
Get node addressString
getDatacenter()
Get node datacenterString
getId()
Get node idString
getLanAddress()
Get node lan addressString
getName()
Get node nameMap<String,String>
getNodeMeta()
Get node metaString
getWanAddress()
Get node wan addressint
hashCode()
Node
setAddress(String address)
Set node addressNode
setDatacenter(String datacenter)
Set node datacenterNode
setId(String id)
Set node idNode
setLanAddress(String lanAddress)
Set node lan addressNode
setName(String node)
Set node nameNode
setNodeMeta(Map<String,String> nodeMeta)
Set node metaNode
setWanAddress(String wanAddress)
Set node wan addressJsonObject
toJson()
Convert to JSON
-
-
-
Constructor Detail
-
Node
public Node()
Default constructor
-
Node
public Node(Node other)
Copy constructor- Parameters:
other
- the one to copy
-
Node
public Node(JsonObject json)
Constructor from JSON- Parameters:
json
- the JSON
-
-
Method Detail
-
toJson
public JsonObject toJson()
Convert to JSON- Returns:
- the JSON
-
getId
public String getId()
Get node id- Returns:
- node id
-
getName
public String getName()
Get node name- Returns:
- node name
-
getAddress
public String getAddress()
Get node address- Returns:
- node address
-
getLanAddress
public String getLanAddress()
Get node lan address- Returns:
- node lan address
-
getWanAddress
public String getWanAddress()
Get node wan address- Returns:
- node wan address
-
getDatacenter
public String getDatacenter()
Get node datacenter- Returns:
- node datacenter
-
setId
public Node setId(String id)
Set node id- Parameters:
id
- node id- Returns:
- reference to this, for fluency
-
setName
public Node setName(String node)
Set node name- Parameters:
node
- node name- Returns:
- reference to this, for fluency
-
setAddress
public Node setAddress(String address)
Set node address- Parameters:
address
- node address- Returns:
- reference to this, for fluency
-
setLanAddress
public Node setLanAddress(String lanAddress)
Set node lan address- Parameters:
lanAddress
- node lan address- Returns:
- reference to this, for fluency
-
setWanAddress
public Node setWanAddress(String wanAddress)
Set node wan address- Parameters:
wanAddress
- node wan address- Returns:
- reference to this, for fluency
-
setDatacenter
public Node setDatacenter(String datacenter)
Set node datacenter- Parameters:
datacenter
- node datacenter- Returns:
- reference to this, for fluency
-
setNodeMeta
public Node setNodeMeta(Map<String,String> nodeMeta)
Set node meta- Parameters:
nodeMeta
- node nodeMeta- Returns:
- reference to this, for fluency
-
-