@Generated(value={"Immutables.generator","Config"}) public final class ImmutableConfig extends Config
Config.
Use the builder to create immutable instances:
ImmutableConfig.builder().
| Modifier and Type | Class and Description |
|---|---|
static class |
ImmutableConfig.Builder
Builds instances of type
ImmutableConfig. |
| Modifier and Type | Method and Description |
|---|---|
static ImmutableConfig.Builder |
builder()
Creates a builder for
ImmutableConfig. |
static ImmutableConfig |
copyOf(Config instance)
Creates an immutable copy of a
Config value. |
String |
dnsRecursor() |
boolean |
equals(Object another)
This instance is equal to all instances of
ImmutableConfig that have equal attribute values. |
String |
getAdvertiseAddr() |
String |
getBindAddr() |
boolean |
getBootstrap() |
String |
getCaFile() |
String |
getCertFile() |
String |
getClientAddr() |
String |
getDatacenter() |
String |
getDataDir() |
String |
getDomain() |
boolean |
getEnableDebug() |
boolean |
getEnableSyslog() |
String |
getKeyFile() |
boolean |
getLeaveOnTerm() |
String |
getLogLevel() |
String |
getNodeName() |
String |
getPidFile() |
Ports |
getPorts() |
int |
getProtocol() |
boolean |
getRejoinAfterLeave() |
boolean |
getServer() |
boolean |
getSkipLeaveOnInt() |
com.google.common.collect.ImmutableList<String> |
getStartJoin() |
com.google.common.base.Optional<String> |
getStatsiteAddr()
Deprecated.
GET /v1/agent/self from v0.6.4 does not have this JSON field
|
com.google.common.base.Optional<Telemetry> |
getTelemetry()
New version of consul has Telemetry field
TODO: Have to think about back compatibility (I think we shouldn't)
|
String |
getUiDir() |
boolean |
getVerifyIncoming() |
boolean |
getVerifyOutgoing() |
int |
hashCode()
Computes a hash code from attributes:
bootstrap, server, datacenter, dataDir, dnsRecursor, domain, logLevel, nodeName, clientAddr, bindAddr, advertiseAddr, ports, leaveOnTerm, skipLeaveOnInt, statsiteAddr, protocol, enableDebug, verifyIncoming, verifyOutgoing, caFile, certFile, keyFile, startJoin, uiDir, pidFile, enableSyslog, rejoinAfterLeave, telemetry. |
String |
toString()
Prints the immutable value
Config with attribute values. |
ImmutableConfig |
withAdvertiseAddr(String value)
Copy the current immutable object by setting a value for the
advertiseAddr attribute. |
ImmutableConfig |
withBindAddr(String value)
Copy the current immutable object by setting a value for the
bindAddr attribute. |
ImmutableConfig |
withBootstrap(boolean value)
Copy the current immutable object by setting a value for the
bootstrap attribute. |
ImmutableConfig |
withCaFile(String value)
Copy the current immutable object by setting a value for the
caFile attribute. |
ImmutableConfig |
withCertFile(String value)
Copy the current immutable object by setting a value for the
certFile attribute. |
ImmutableConfig |
withClientAddr(String value)
Copy the current immutable object by setting a value for the
clientAddr attribute. |
ImmutableConfig |
withDatacenter(String value)
Copy the current immutable object by setting a value for the
datacenter attribute. |
ImmutableConfig |
withDataDir(String value)
Copy the current immutable object by setting a value for the
dataDir attribute. |
ImmutableConfig |
withDnsRecursor(String value)
Copy the current immutable object by setting a value for the
dnsRecursor attribute. |
ImmutableConfig |
withDomain(String value)
Copy the current immutable object by setting a value for the
domain attribute. |
ImmutableConfig |
withEnableDebug(boolean value)
Copy the current immutable object by setting a value for the
enableDebug attribute. |
ImmutableConfig |
withEnableSyslog(boolean value)
Copy the current immutable object by setting a value for the
enableSyslog attribute. |
ImmutableConfig |
withKeyFile(String value)
Copy the current immutable object by setting a value for the
keyFile attribute. |
ImmutableConfig |
withLeaveOnTerm(boolean value)
Copy the current immutable object by setting a value for the
leaveOnTerm attribute. |
ImmutableConfig |
withLogLevel(String value)
Copy the current immutable object by setting a value for the
logLevel attribute. |
ImmutableConfig |
withNodeName(String value)
Copy the current immutable object by setting a value for the
nodeName attribute. |
ImmutableConfig |
withPidFile(String value)
Copy the current immutable object by setting a value for the
pidFile attribute. |
ImmutableConfig |
withPorts(Ports value)
Copy the current immutable object by setting a value for the
ports attribute. |
ImmutableConfig |
withProtocol(int value)
Copy the current immutable object by setting a value for the
protocol attribute. |
ImmutableConfig |
withRejoinAfterLeave(boolean value)
Copy the current immutable object by setting a value for the
rejoinAfterLeave attribute. |
ImmutableConfig |
withServer(boolean value)
Copy the current immutable object by setting a value for the
server attribute. |
ImmutableConfig |
withSkipLeaveOnInt(boolean value)
Copy the current immutable object by setting a value for the
skipLeaveOnInt attribute. |
ImmutableConfig |
withStartJoin(Iterable<String> elements)
Copy the current immutable object with elements that replace the content of
startJoin. |
ImmutableConfig |
withStartJoin(String... elements)
Copy the current immutable object with elements that replace the content of
startJoin. |
ImmutableConfig |
withStatsiteAddr(com.google.common.base.Optional<String> optional)
Deprecated.
|
ImmutableConfig |
withStatsiteAddr(String value)
Deprecated.
|
ImmutableConfig |
withTelemetry(com.google.common.base.Optional<Telemetry> optional)
Copy the current immutable object by setting an optional value for the
telemetry attribute. |
ImmutableConfig |
withTelemetry(Telemetry value)
Copy the current immutable object by setting a present value for the optional
telemetry attribute. |
ImmutableConfig |
withUiDir(String value)
Copy the current immutable object by setting a value for the
uiDir attribute. |
ImmutableConfig |
withVerifyIncoming(boolean value)
Copy the current immutable object by setting a value for the
verifyIncoming attribute. |
ImmutableConfig |
withVerifyOutgoing(boolean value)
Copy the current immutable object by setting a value for the
verifyOutgoing attribute. |
public boolean getBootstrap()
getBootstrap in class Configbootstrap attributepublic boolean getServer()
public String getDatacenter()
getDatacenter in class Configdatacenter attributepublic String getDataDir()
getDataDir in class ConfigdataDir attributepublic String dnsRecursor()
dnsRecursor in class ConfigdnsRecursor attributepublic String getDomain()
public String getLogLevel()
getLogLevel in class ConfiglogLevel attributepublic String getNodeName()
getNodeName in class ConfignodeName attributepublic String getClientAddr()
getClientAddr in class ConfigclientAddr attributepublic String getBindAddr()
getBindAddr in class ConfigbindAddr attributepublic String getAdvertiseAddr()
getAdvertiseAddr in class ConfigadvertiseAddr attributepublic Ports getPorts()
public boolean getLeaveOnTerm()
getLeaveOnTerm in class ConfigleaveOnTerm attributepublic boolean getSkipLeaveOnInt()
getSkipLeaveOnInt in class ConfigskipLeaveOnInt attribute@Deprecated public com.google.common.base.Optional<String> getStatsiteAddr()
getStatsiteAddr in class Configpublic int getProtocol()
getProtocol in class Configprotocol attributepublic boolean getEnableDebug()
getEnableDebug in class ConfigenableDebug attributepublic boolean getVerifyIncoming()
getVerifyIncoming in class ConfigverifyIncoming attributepublic boolean getVerifyOutgoing()
getVerifyOutgoing in class ConfigverifyOutgoing attributepublic String getCaFile()
public String getCertFile()
getCertFile in class ConfigcertFile attributepublic String getKeyFile()
getKeyFile in class ConfigkeyFile attributepublic com.google.common.collect.ImmutableList<String> getStartJoin()
getStartJoin in class ConfigstartJoin attributepublic String getUiDir()
public String getPidFile()
getPidFile in class ConfigpidFile attributepublic boolean getEnableSyslog()
getEnableSyslog in class ConfigenableSyslog attributepublic boolean getRejoinAfterLeave()
getRejoinAfterLeave in class ConfigrejoinAfterLeave attributepublic com.google.common.base.Optional<Telemetry> getTelemetry()
getTelemetry in class Configpublic final ImmutableConfig withBootstrap(boolean value)
bootstrap attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for bootstrapthis objectpublic final ImmutableConfig withServer(boolean value)
server attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for serverthis objectpublic final ImmutableConfig withDatacenter(String value)
datacenter attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for datacenterthis objectpublic final ImmutableConfig withDataDir(String value)
dataDir attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for dataDirthis objectpublic final ImmutableConfig withDnsRecursor(String value)
dnsRecursor attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for dnsRecursorthis objectpublic final ImmutableConfig withDomain(String value)
domain attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for domainthis objectpublic final ImmutableConfig withLogLevel(String value)
logLevel attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for logLevelthis objectpublic final ImmutableConfig withNodeName(String value)
nodeName attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for nodeNamethis objectpublic final ImmutableConfig withClientAddr(String value)
clientAddr attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for clientAddrthis objectpublic final ImmutableConfig withBindAddr(String value)
bindAddr attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for bindAddrthis objectpublic final ImmutableConfig withAdvertiseAddr(String value)
advertiseAddr attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for advertiseAddrthis objectpublic final ImmutableConfig withPorts(Ports value)
ports attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for portsthis objectpublic final ImmutableConfig withLeaveOnTerm(boolean value)
leaveOnTerm attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for leaveOnTermthis objectpublic final ImmutableConfig withSkipLeaveOnInt(boolean value)
skipLeaveOnInt attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for skipLeaveOnIntthis object@Deprecated public final ImmutableConfig withStatsiteAddr(String value)
statsiteAddr attribute.value - The value for statsiteAddrthis object@Deprecated public final ImmutableConfig withStatsiteAddr(com.google.common.base.Optional<String> optional)
statsiteAddr attribute.
An equality check is used to prevent copying of the same value by returning this.optional - A value for statsiteAddrthis objectpublic final ImmutableConfig withProtocol(int value)
protocol attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for protocolthis objectpublic final ImmutableConfig withEnableDebug(boolean value)
enableDebug attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for enableDebugthis objectpublic final ImmutableConfig withVerifyIncoming(boolean value)
verifyIncoming attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for verifyIncomingthis objectpublic final ImmutableConfig withVerifyOutgoing(boolean value)
verifyOutgoing attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for verifyOutgoingthis objectpublic final ImmutableConfig withCaFile(String value)
caFile attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for caFilethis objectpublic final ImmutableConfig withCertFile(String value)
certFile attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for certFilethis objectpublic final ImmutableConfig withKeyFile(String value)
keyFile attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for keyFilethis objectpublic final ImmutableConfig withStartJoin(String... elements)
startJoin.elements - The elements to setthis objectpublic final ImmutableConfig withStartJoin(Iterable<String> elements)
startJoin.
A shallow reference equality check is used to prevent copying of the same value by returning this.elements - An iterable of startJoin elements to setthis objectpublic final ImmutableConfig withUiDir(String value)
uiDir attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for uiDirthis objectpublic final ImmutableConfig withPidFile(String value)
pidFile attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for pidFilethis objectpublic final ImmutableConfig withEnableSyslog(boolean value)
enableSyslog attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for enableSyslogthis objectpublic final ImmutableConfig withRejoinAfterLeave(boolean value)
rejoinAfterLeave attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for rejoinAfterLeavethis objectpublic final ImmutableConfig withTelemetry(Telemetry value)
telemetry attribute.value - The value for telemetrythis objectpublic final ImmutableConfig withTelemetry(com.google.common.base.Optional<Telemetry> optional)
telemetry attribute.
A shallow reference equality check on the optional value is used to prevent copying of the same value by returning this.optional - A value for telemetrythis objectpublic boolean equals(Object another)
ImmutableConfig that have equal attribute values.public int hashCode()
bootstrap, server, datacenter, dataDir, dnsRecursor, domain, logLevel, nodeName, clientAddr, bindAddr, advertiseAddr, ports, leaveOnTerm, skipLeaveOnInt, statsiteAddr, protocol, enableDebug, verifyIncoming, verifyOutgoing, caFile, certFile, keyFile, startJoin, uiDir, pidFile, enableSyslog, rejoinAfterLeave, telemetry.public String toString()
Config with attribute values.public static ImmutableConfig copyOf(Config instance)
Config value.
Uses accessors to get values to initialize the new immutable instance.
If an instance is already immutable, it is returned as is.instance - The instance to copypublic static ImmutableConfig.Builder builder()
ImmutableConfig.Copyright © 2016. All rights reserved.