public class GetSubnetIPAs
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private int |
backlog |
(package private) int |
BACKLOG |
private java.lang.String |
ipa |
private java.util.ArrayList<java.lang.String> |
ipaSubnet |
(package private) boolean |
LOG_SELF |
(package private) java.lang.String |
OS_PING_EXECUTABLE |
private int |
port |
private Server |
server |
Constructor and Description |
---|
GetSubnetIPAs(int newPort,
int newBacklog,
java.lang.String newIPA)
this is the constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
discoverSubnet(java.lang.String[] args)
this scours the 254 subnet network addresses adjoining the base IPA and
// returns a list of the discovered addresses.
|
private int |
getHiIPA(java.lang.String[] args)
this attempts to recover and then return the IPA address high range value
// from the console input argument string.
|
private int |
getLowIPA(java.lang.String[] args)
this attempts to recover and then return the IPA address low range value
// from the console input argument string.
|
java.util.ArrayList<java.lang.String> |
getSubnetList()
this returns the values of the discovered IPAs as an Array List.
|
static java.lang.String |
parseStr(java.lang.String sample,
java.lang.String target)
this method parses input passed by the command line to locate and return
// the value of an argument.
|
boolean |
ping(java.net.InetAddress ipaInetAddr)
this uses an Operating System specific "ping" command to check for an
// active (and DNS port 53 responsive) IPA.
|
private boolean |
pingHelper(java.io.BufferedReader input,
java.lang.String searchText)
this processes the data in the BufferedReader input passed to it
// and returns a Boolean true if the String searchText can be found.
|
void |
template()
this method does nothing.
|
final boolean LOG_SELF
final int BACKLOG
final java.lang.String OS_PING_EXECUTABLE
private int port
private int backlog
private java.lang.String ipa
private java.util.ArrayList<java.lang.String> ipaSubnet
private Server server
public GetSubnetIPAs(int newPort, int newBacklog, java.lang.String newIPA)
public void discoverSubnet(java.lang.String[] args)
public java.util.ArrayList<java.lang.String> getSubnetList()
private int getLowIPA(java.lang.String[] args)
private int getHiIPA(java.lang.String[] args)
public static java.lang.String parseStr(java.lang.String sample, java.lang.String target)
public boolean ping(java.net.InetAddress ipaInetAddr)
private boolean pingHelper(java.io.BufferedReader input, java.lang.String searchText)
public void template()