|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
The IDhcpService is used to set up dhcpserver on a particular adapter. To setup the dhcp server for first time use setDhcpServer(String adapter,int defaultLeaseTime, int maximumLeaseTime, String subnetMask, String rangeFrom, String rangeTo, boolean passDnsServers) method call followed by runDhcpServer(string adapter) method call. The individual dhcp server parameters can be set by using any of the set calls and can be read by using the get calls. To make changes to DHCPserver settings on the fly use the set commands and then manually restart the udhcpd daemon.
Field Summary | |
static java.lang.String |
SERVICE_NAME
service name of this interface for the bundle activator com.esf.net.dhcp.server.service |
Method Summary | |
boolean |
closeDhcpServer(java.lang.String adapter)
Shuts down the Dhcp server for this Ethernet adapter. |
int |
getDhcpServerDefaultLeaseTime(java.lang.String adapter)
Reports the default lease time to be used by the DHCP server service on this Ethernet adapter. |
int |
getDhcpServerMaximumLeaseTime(java.lang.String adapter)
Reports the maximum lease time to be used by the DHCP server service on this Ethernet adapter. |
java.lang.String |
getDhcpServerRangeFrom(java.lang.String adapter)
Reports the IP address representing the beginning of the range of addresses to be served by the DHCP server service on this Ethernet adapter. |
java.lang.String |
getDhcpServerRangeTo(java.lang.String adapter)
Reports the IP address representing the end of the range of addresses to be served by the DHCP server service on this Ethernet adapter. |
java.lang.String |
getDhcpServerSubnetMask(java.lang.String adapter)
Reports the IP subnet mask to be used by the DHCP server service on this Ethernet adapter. |
boolean |
runDhcpServer(java.lang.String adapter)
Reports the whether this adapter has been configured to provide DHCP server service. |
void |
setDhcpServer(java.lang.String adapter,
int defaultLeaseTime,
int maximumLeaseTime,
java.lang.String subnetMask,
java.lang.String rangeFrom,
java.lang.String rangeTo,
boolean passDnsServers)
sets the dhcp server parameters of a statically defined Ethernet interface |
void |
setDhcpServerDefaultLeaseTime(java.lang.String adapter,
int defaultleasetime)
sets the default lease time to be used by the DHCP server service on this Ethernet adapter. |
void |
setDhcpServerMaximumLeaseTime(java.lang.String adapter,
int maximumleasetime)
Sets the maximum lease time to be used by the DHCP server service on this Ethernet adapter. |
void |
setDhcpServerRangeFrom(java.lang.String adapter,
java.lang.String serverRangefrom)
Sets the IP address representing the beginning of the range of addresses to be served by the DHCP server service on this Ethernet adapter. |
void |
setDhcpServerRangeTo(java.lang.String adapter,
java.lang.String serverRangeto)
Sets the IP address representing the end of the range of addresses to be served by the DHCP server service on this Ethernet adapter. |
void |
setDhcpServerSubnetMask(java.lang.String adapter,
java.lang.String subnetMask)
Sets the IP subnet mask to be used by the DHCP server service on this Ethernet adapter. |
boolean |
willDhcpServerPassDnsServers(java.lang.String adapter)
Reports whether the DHCP server service will pass DNS server addresses for this Ethernet adapter. |
Field Detail |
public static final java.lang.String SERVICE_NAME
Method Detail |
public void setDhcpServer(java.lang.String adapter, int defaultLeaseTime, int maximumLeaseTime, java.lang.String subnetMask, java.lang.String rangeFrom, java.lang.String rangeTo, boolean passDnsServers) throws java.lang.Exception
adapter
- = requested adapter.defaultLeaseTime
- the default lease time to configure in seconds,maximumLeaseTime
- maximum lease time to be used by the server in
seconds,subnetMask
- the IP subnet mask to be usedrangeFrom
- IP address representing the beginning of the range of
addresses to be served by the DHCP serverrangeTo
- IP address representing the end of the range of addresses
to be served by the DHCP serverpassDnsServers
- 0 for no dnsserver pass and 1 to pass dnsserver
java.lang.Exception
- if any parameters are invalidpublic boolean runDhcpServer(java.lang.String adapter)
adapter
- = requested adapter.
public int getDhcpServerDefaultLeaseTime(java.lang.String adapter) throws java.lang.Exception
adapter
- = requested adapter.
java.lang.Exception
public int getDhcpServerMaximumLeaseTime(java.lang.String adapter) throws java.lang.Exception
adapter
- = requested adapter.
java.lang.Exception
public java.lang.String getDhcpServerSubnetMask(java.lang.String adapter) throws java.lang.Exception
adapter
- = requested adapter.
java.lang.Exception
public java.lang.String getDhcpServerRangeFrom(java.lang.String adapter) throws java.lang.Exception
adapter
- = requested adapter.
java.lang.Exception
public java.lang.String getDhcpServerRangeTo(java.lang.String adapter) throws java.lang.Exception
adapter
- = requested adapter.
java.lang.Exception
public void setDhcpServerDefaultLeaseTime(java.lang.String adapter, int defaultleasetime) throws java.lang.Exception
adapter
- = requested adapter.defaultleasetime
- = default lease time to set in seconds,
java.lang.Exception
- if any parameters are invalidpublic void setDhcpServerMaximumLeaseTime(java.lang.String adapter, int maximumleasetime) throws java.lang.Exception
adapter
- = requested adapter.maximumleasetime
- = maximum lease time to set in seconds
java.lang.Exception
- if any parameters are invalidpublic void setDhcpServerSubnetMask(java.lang.String adapter, java.lang.String subnetMask) throws java.lang.Exception
adapter
- = requested adapter.subnetMask
- = the subnet mask ip address to be set
java.lang.Exception
- if any parameters are invalidpublic void setDhcpServerRangeFrom(java.lang.String adapter, java.lang.String serverRangefrom) throws java.lang.Exception
adapter
- = requested adapter.serverRangefrom
- = starting ip address of the DHCP server range
java.lang.Exception
- if any parameters are invalidpublic void setDhcpServerRangeTo(java.lang.String adapter, java.lang.String serverRangeto) throws java.lang.Exception
adapter
- = requested adapter.serverRangeto
- = Ending ip address of the DHCP server range
java.lang.Exception
- if any parameters are invalidpublic boolean willDhcpServerPassDnsServers(java.lang.String adapter) throws java.lang.Exception
adapter
- = requested adapter
java.lang.Exception
public boolean closeDhcpServer(java.lang.String adapter) throws java.lang.Exception
adapter
- = requested adapter
java.lang.Exception
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |