Top Description Fields Constructors Methods
io.vertx.core.dns

public Class DnsClientOptions

extends Object
Class Inheritance
Annotations
@DataObject
@JsonGen
publicConverter:false
Imports
io.vertx.codegen.annotations.DataObject, io.vertx.codegen.json.annotations.JsonGen, io.vertx.core.VertxOptions, io.vertx.core.json.JsonObject, io.netty.handler.logging.ByteBufFormat

Configuration options for Vert.x DNS client.
Author
Julien Viet

Field Summary

Modifier and TypeField and Description
private ByteBufFormat
public static final String
DEFAULT_HOST

The default value for the host = null (configured by VertxOptions#getAddressResolverOptions())

public static final ByteBufFormat
DEFAULT_LOG_ACTIVITY_FORMAT

The default ByteBufFormat is SIMPLE

public static final boolean
DEFAULT_LOG_ENABLED

The default log enabled = false

public static final int
DEFAULT_PORT

The default value for the port = -1 (configured by VertxOptions#getAddressResolverOptions())

public static final long
DEFAULT_QUERY_TIMEOUT

The default value for the query timeout in millis = 5000

public static final boolean
DEFAULT_RECURSION_DESIRED

The default value for the recursion desired flag (RD) = true

private String
private boolean
private int
private long
private boolean

Constructor Summary

AccessConstructor and Description
public
public
DnsClientOptions(JsonObject json)
References Deprecated JsonObject is deprecated or references (maybe indirectly) at least one deprecated element.

public

Method Summary

Modifier and TypeMethod and Description
public ByteBufFormat

Returns:

ByteBufFormat get Netty's log format
getActivityLogFormat
()

public String

Returns:

the host name
getHost
()

Get the host name to be used by this client in requests.

public boolean

Returns:

true when network activity logging is enabled
getLogActivity
()

public int

Returns:

the port
getPort
()

Get the port to be used by this client in requests.

public long

Returns:

the query timeout in milliseconds
getQueryTimeout
()

public boolean

Returns:

true when recursion is desired
isRecursionDesired
()

Return whether or not recursion is desired

public DnsClientOptions

Returns:

a reference to this, so the API can be used fluently
setActivityLogFormat
(ByteBufFormat
format of Netty's logging data
activityLogFormat
)

Set the value of Netty's logging handler's data format: Netty's pipeline is configured for logging on Netty's logger.

public DnsClientOptions

Returns:

a reference to this, so the API can be used fluently
setHost
(String host)

Set the host name to be used by this client in requests.

public DnsClientOptions

Returns:

a reference to this, so the API can be used fluently
setLogActivity
(boolean
true for logging the network activity
logActivity
)

Set to true to enable network activity logging: Netty's pipeline is configured for logging on Netty's logger.

public DnsClientOptions

Returns:

a reference to this, so the API can be used fluently
setPort
(int port)

Set the port to be used by this client in requests.

public DnsClientOptions

Returns:

a reference to this, so the API can be used fluently
setQueryTimeout
(long
the query timeout in milliseconds
queryTimeout
)

Set the query timeout in milliseconds, i.e the amount of time after a query is considered to be failed.

public DnsClientOptions

Returns:

a reference to this, so the API can be used fluently
setRecursionDesired
(boolean
the new value
recursionDesired
)

Set whether or not recursion is desired

public JsonObject
toJson()
References Deprecated JsonObject is deprecated or references (maybe indirectly) at least one deprecated element.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

activityLogFormatback to summary
private ByteBufFormat activityLogFormat
DEFAULT_HOSTback to summary
public static final String DEFAULT_HOST

The default value for the host = null (configured by VertxOptions#getAddressResolverOptions())

DEFAULT_LOG_ACTIVITY_FORMATback to summary
public static final ByteBufFormat DEFAULT_LOG_ACTIVITY_FORMAT

The default ByteBufFormat is SIMPLE

DEFAULT_LOG_ENABLEDback to summary
public static final boolean DEFAULT_LOG_ENABLED

The default log enabled = false

DEFAULT_PORTback to summary
public static final int DEFAULT_PORT

The default value for the port = -1 (configured by VertxOptions#getAddressResolverOptions())

DEFAULT_QUERY_TIMEOUTback to summary
public static final long DEFAULT_QUERY_TIMEOUT

The default value for the query timeout in millis = 5000

DEFAULT_RECURSION_DESIREDback to summary
public static final boolean DEFAULT_RECURSION_DESIRED

The default value for the recursion desired flag (RD) = true

hostback to summary
private String host
logActivityback to summary
private boolean logActivity
portback to summary
private int port
queryTimeoutback to summary
private long queryTimeout
recursionDesiredback to summary
private boolean recursionDesired

Constructor Detail

DnsClientOptionsback to summary
public DnsClientOptions()
DnsClientOptionsback to summary
public DnsClientOptions(JsonObject json)

References Deprecated

JsonObject is deprecated or references (maybe indirectly) at least one deprecated element.

See corresponding docs for further information.

DnsClientOptionsback to summary
public DnsClientOptions(DnsClientOptions other)

Method Detail

getActivityLogFormatback to summary
public ByteBufFormat getActivityLogFormat()
Returns:ByteBufFormat

ByteBufFormat get Netty's log format

getHostback to summary
public String getHost()

Get the host name to be used by this client in requests.

Returns:String

the host name

getLogActivityback to summary
public boolean getLogActivity()
Returns:boolean

true when network activity logging is enabled

getPortback to summary
public int getPort()

Get the port to be used by this client in requests.

Returns:int

the port

getQueryTimeoutback to summary
public long getQueryTimeout()
Returns:long

the query timeout in milliseconds

isRecursionDesiredback to summary
public boolean isRecursionDesired()

Return whether or not recursion is desired

Returns:boolean

true when recursion is desired

setActivityLogFormatback to summary
public DnsClientOptions setActivityLogFormat(ByteBufFormat activityLogFormat)

Set the value of Netty's logging handler's data format: Netty's pipeline is configured for logging on Netty's logger.

Parameters
activityLogFormat:ByteBufFormat

format of Netty's logging data

Returns:DnsClientOptions

a reference to this, so the API can be used fluently

setHostback to summary
public DnsClientOptions setHost(String host)

Set the host name to be used by this client in requests.

Returns:DnsClientOptions

a reference to this, so the API can be used fluently

setLogActivityback to summary
public DnsClientOptions setLogActivity(boolean logActivity)

Set to true to enable network activity logging: Netty's pipeline is configured for logging on Netty's logger.

Parameters
logActivity:boolean

true for logging the network activity

Returns:DnsClientOptions

a reference to this, so the API can be used fluently

setPortback to summary
public DnsClientOptions setPort(int port)

Set the port to be used by this client in requests.

Returns:DnsClientOptions

a reference to this, so the API can be used fluently

setQueryTimeoutback to summary
public DnsClientOptions setQueryTimeout(long queryTimeout)

Set the query timeout in milliseconds, i.e the amount of time after a query is considered to be failed.

Parameters
queryTimeout:long

the query timeout in milliseconds

Returns:DnsClientOptions

a reference to this, so the API can be used fluently

setRecursionDesiredback to summary
public DnsClientOptions setRecursionDesired(boolean recursionDesired)

Set whether or not recursion is desired

Parameters
recursionDesired:boolean

the new value

Returns:DnsClientOptions

a reference to this, so the API can be used fluently

toJsonback to summary
public JsonObject toJson()

References Deprecated

JsonObject is deprecated or references (maybe indirectly) at least one deprecated element.

See corresponding docs for further information.