com.esf.net.dhcp.server.service
Class DhcpServerParameters

java.lang.Object
  extended bycom.esf.net.dhcp.server.service.DhcpServerParameters

public final class DhcpServerParameters
extends java.lang.Object

Constructor to hold the parameters of a DHCP server configuration.


Constructor Summary
DhcpServerParameters(int defaultLeaseTime, int maximumLeaseTime, java.lang.String subnetMask, java.lang.String rangeFrom, java.lang.String rangeTo, boolean passDnsServers)
           
 
Method Summary
 int getDefaultLeaseTime()
          gets the default lease time
 int getMaximumLeaseTime()
          gets the max lease time
 java.lang.String getRangeFrom()
          gets the starting IP of the DHCP range being served
 java.lang.String getRangeTo()
          gets the ending IP of the DHCP range being served
 java.lang.String getSubnetMask()
          gets the subnet mask of the DHCP range
 boolean isPassDnsServers()
          gets the configuration state of whether to pass DNS servers to DHCP clients
 void setDefaultLeaseTime(int defaultLeaseTime)
          sets the default lease time
 void setMaximumLeaseTime(int maximumLeaseTime)
          sets the max lease time
 void setPassDnsServers(boolean passDnsServers)
          sets whether to pass DNS servers to DHCP clients
 void setRangeFrom(java.lang.String rangeFrom)
          sets the starting IP of the DHCP range being served
 void setRangeTo(java.lang.String rangeTo)
          sets the ending IP of the DHCP range being served
 void setSubnetMask(java.lang.String subnetMask)
          sets the subnet mask of the DHCP range
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DhcpServerParameters

public DhcpServerParameters(int defaultLeaseTime,
                            int maximumLeaseTime,
                            java.lang.String subnetMask,
                            java.lang.String rangeFrom,
                            java.lang.String rangeTo,
                            boolean passDnsServers)
Parameters:
defaultLeaseTime - Default lease time as int, in seconds
maximumLeaseTime - Max lease time as int, in seconds
subnetMask - Subnet mask of DHCP server range as String (such as "255.255.255.0")
rangeFrom - Starting IP address of range of DHCP addresses to be served
rangeTo - Ending IP address of range of DHCP addresses to be served
passDnsServers - true to pass DNS server addresses to DHCP client, false otherwise
Method Detail

getDefaultLeaseTime

public int getDefaultLeaseTime()
gets the default lease time

Returns:
lease time in seconds

setDefaultLeaseTime

public void setDefaultLeaseTime(int defaultLeaseTime)
sets the default lease time

Parameters:
defaultLeaseTime - in seconds

getMaximumLeaseTime

public int getMaximumLeaseTime()
gets the max lease time

Returns:
max lease time in seconds

setMaximumLeaseTime

public void setMaximumLeaseTime(int maximumLeaseTime)
sets the max lease time

Parameters:
maximumLeaseTime - in seconds

isPassDnsServers

public boolean isPassDnsServers()
gets the configuration state of whether to pass DNS servers to DHCP clients

Returns:
as boolean

setPassDnsServers

public void setPassDnsServers(boolean passDnsServers)
sets whether to pass DNS servers to DHCP clients

Parameters:
passDnsServers - true to pass DNS, false otherwise

getRangeFrom

public java.lang.String getRangeFrom()
gets the starting IP of the DHCP range being served

Returns:
IP address as String

setRangeFrom

public void setRangeFrom(java.lang.String rangeFrom)
sets the starting IP of the DHCP range being served

Parameters:
rangeFrom - IP as String

getRangeTo

public java.lang.String getRangeTo()
gets the ending IP of the DHCP range being served

Returns:
IP address as String

setRangeTo

public void setRangeTo(java.lang.String rangeTo)
sets the ending IP of the DHCP range being served

Parameters:
rangeTo - IP address as String

getSubnetMask

public java.lang.String getSubnetMask()
gets the subnet mask of the DHCP range

Returns:
subnet mask as String

setSubnetMask

public void setSubnetMask(java.lang.String subnetMask)
sets the subnet mask of the DHCP range

Parameters:
subnetMask - as String


Copyright © 2009 Eurotech Inc. All rights reserved.