org.nhindirect.dns
Class DNSServerSettings

java.lang.Object
  extended by org.nhindirect.dns.SocketServerSettings
      extended by org.nhindirect.dns.DNSServerSettings

public class DNSServerSettings
extends SocketServerSettings

Tuning parameters for the DNS server.

Since:
1.0
Author:
Greg Meyer, Umesh Madan, Chris Lomonico

Field Summary
static int DAFAULT_MAX_REQUEST_SIZE
           
 
Constructor Summary
DNSServerSettings()
          Create default DNS server settings
 
Method Summary
 String getBindAddress()
          Gets the IP4 addresses that the server will be bound to.
 int getMaxRequestSize()
          Gets the maximum size in bytes of a request.
 int getPort()
          Gets the IP port that the server will be listening on.
 void setBindAddress(String bindAddress)
          Sets the IP4 addresses that the server will be bound to.
 void setMaxRequestSize(int maxRequestSize)
          Sets the maximum size in bytes of a request.
 void setPort(int port)
          Sets the IP port that the server will be listening on.
 
Methods inherited from class org.nhindirect.dns.SocketServerSettings
getMaxActiveRequests, getMaxConnectionBacklog, getMaxOutstandingAccepts, getReadBufferSize, getReceiveTimeout, getSendTimeout, getSocketCloseTimeout, setMaxActiveRequests, setMaxConnectionBacklog, setMaxOutstandingAccepts, setReadBufferSize, setReceiveTimeout, setSendTimeout, setSocketCloseTimeout
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DAFAULT_MAX_REQUEST_SIZE

public static final int DAFAULT_MAX_REQUEST_SIZE
See Also:
Constant Field Values
Constructor Detail

DNSServerSettings

public DNSServerSettings()
Create default DNS server settings

Method Detail

getPort

public int getPort()
Gets the IP port that the server will be listening on. The default is 53.

Returns:
The IP port that the server will be listening on.

setPort

public void setPort(int port)
Sets the IP port that the server will be listening on.

Parameters:
port - The IP port that the server will be listening on.

getBindAddress

public String getBindAddress()
Gets the IP4 addresses that the server will be bound to. The string is comma delimited list of IP addresses. The default is 0.0.0.0 which means that the server will bind to add IP addresses available on the local machine.

Returns:
The IP4 addresses that the server will be bound to.

setBindAddress

public void setBindAddress(String bindAddress)
Sets the IP4 addresses that the server will be bound to.

Parameters:
bindAddress - The IP4 addresses that the server will be bound to.

getMaxRequestSize

public int getMaxRequestSize()
Gets the maximum size in bytes of a request. The default size is 16K.

Returns:
The maximum size in bytes of a request.

setMaxRequestSize

public void setMaxRequestSize(int maxRequestSize)
Sets the maximum size in bytes of a request.

Parameters:
maxRequestSize - The maximum size in bytes of a request.


Copyright © 2010-2015 The Direct Project. All Rights Reserved.