Constructor and Description |
---|
DefaultNodeInfo(NetworkAddress hostname,
Map<ServiceType,Integer> direct,
Map<ServiceType,Integer> ssl,
Map<String,AlternateAddress> alternateAddresses)
Creates a new
DefaultNodeInfo with SSL services. |
DefaultNodeInfo(String viewUri,
String hostname,
Map<String,Integer> ports,
Map<String,AlternateAddress> alternateAddresses)
Creates a new
DefaultNodeInfo with no SSL services. |
Modifier and Type | Method and Description |
---|---|
Map<String,AlternateAddress> |
alternateAddresses()
Contains alternate addresses, if set.
|
NetworkAddress |
hostname()
The inet address of the node.
|
String |
rawHostname()
Contains the string representation from the hostname the same way it is represented in the config.
|
Map<ServiceType,Integer> |
services()
The exposed non-ssl services.
|
Map<ServiceType,Integer> |
sslServices()
The exposed ssl services.
|
String |
toString() |
String |
useAlternateNetwork()
True if alternate addresses should be used, false otherwise.
|
void |
useAlternateNetwork(String useAlternateNetwork)
Setter to set if external networking should be used or not.
|
public DefaultNodeInfo(String viewUri, String hostname, Map<String,Integer> ports, Map<String,AlternateAddress> alternateAddresses)
Creates a new DefaultNodeInfo
with no SSL services.
viewUri
- the URI of the view service.hostname
- the hostname of the node.ports
- the port list of the node services.public DefaultNodeInfo(NetworkAddress hostname, Map<ServiceType,Integer> direct, Map<ServiceType,Integer> ssl, Map<String,AlternateAddress> alternateAddresses)
Creates a new DefaultNodeInfo
with SSL services.
hostname
- the hostname of the node.direct
- the port list of the direct node services.ssl
- the port list of the ssl node services.public NetworkAddress hostname()
NodeInfo
The inet address of the node.
public Map<ServiceType,Integer> services()
NodeInfo
The exposed non-ssl services.
public Map<ServiceType,Integer> sslServices()
NodeInfo
The exposed ssl services.
sslServices
in interface NodeInfo
public Map<String,AlternateAddress> alternateAddresses()
NodeInfo
Contains alternate addresses, if set.
alternateAddresses
in interface NodeInfo
public String rawHostname()
NodeInfo
Contains the string representation from the hostname the same way it is represented in the config.
rawHostname
in interface NodeInfo
public String useAlternateNetwork()
NodeInfo
True if alternate addresses should be used, false otherwise.
useAlternateNetwork
in interface NodeInfo
public void useAlternateNetwork(String useAlternateNetwork)
NodeInfo
Setter to set if external networking should be used or not.
useAlternateNetwork
in interface NodeInfo
useAlternateNetwork
- if not null will be used.Copyright © 2018 Couchbase, Inc.. All rights reserved.