org.opengts.util
Class IPTools.IPAddress

java.lang.Object
  extended by org.opengts.util.IPTools.IPAddress
Enclosing class:
IPTools

public static class IPTools.IPAddress
extends java.lang.Object

IPAddress class


Constructor Summary
IPTools.IPAddress(long[] ip)
           
IPTools.IPAddress(long ip, long mask)
           
IPTools.IPAddress(java.lang.String ipAddr)
           
IPTools.IPAddress(java.lang.String ipAddr, int mask)
           
IPTools.IPAddress(java.lang.String ipAddr, long mask)
           
 
Method Summary
protected  java.lang.String _ipToString(long p)
           
 boolean equals(java.lang.Object other)
           
 long getIP()
           
 long getMask()
           
 boolean isMatch(java.lang.String ipAddr)
           
 boolean isZero()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

IPTools.IPAddress

public IPTools.IPAddress(long[] ip)

IPTools.IPAddress

public IPTools.IPAddress(long ip,
                         long mask)

IPTools.IPAddress

public IPTools.IPAddress(java.lang.String ipAddr,
                         int mask)

IPTools.IPAddress

public IPTools.IPAddress(java.lang.String ipAddr,
                         long mask)

IPTools.IPAddress

public IPTools.IPAddress(java.lang.String ipAddr)
Method Detail

getMask

public long getMask()

getIP

public long getIP()

isZero

public boolean isZero()

isMatch

public boolean isMatch(java.lang.String ipAddr)

_ipToString

protected java.lang.String _ipToString(long p)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

equals

public boolean equals(java.lang.Object other)
Overrides:
equals in class java.lang.Object