public class IPv4
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
INVALID_IP_OR_MASK_STRING_SPECIFIED |
static java.lang.String |
INVALID_IP_STRING_SPECIFIED |
Constructor and Description |
---|
IPv4(long ipAddress) |
IPv4(long ipAddress,
long ipMask) |
IPv4(java.lang.String ipAddressStr) |
IPv4(java.lang.String ipAddressStr,
java.lang.String ipMaskStr) |
Modifier and Type | Method and Description |
---|---|
static int |
compareIPv4(IPv4 newIP,
IPv4 oldIP) |
boolean |
equals(java.lang.Object o) |
int |
getA() |
int |
getB() |
int |
getC() |
int |
getD() |
IPv4 |
getFirstIp() |
java.lang.String |
getIpClassName() |
long |
getIpLongValue() |
long |
getIpMask() |
IPv4 |
getLastIp() |
IPv4 |
getNetAddress() |
java.lang.String |
getNetClassRange() |
java.lang.String |
getStringA() |
java.lang.String |
getStringB() |
java.lang.String |
getStringC() |
java.lang.String |
getStringD() |
int |
hashCode() |
boolean |
isIpClassA() |
boolean |
isIpClassB() |
boolean |
isIpClassC() |
boolean |
isNull() |
boolean |
isSaneMask()
Checks if the IP mask is "sane" IP mask is considered to be sane if it
is a sequence of 1s followed by a sequence of 0s.
|
boolean |
isSingleIp() |
static boolean |
isValidIp(java.lang.String ipAddressStr) |
IPv4 |
nextIP() |
IPv4 |
prevIP() |
java.lang.String |
toString() |
public static java.lang.String INVALID_IP_STRING_SPECIFIED
public static java.lang.String INVALID_IP_OR_MASK_STRING_SPECIFIED
public IPv4(long ipAddress)
public IPv4(long ipAddress, long ipMask)
public IPv4(java.lang.String ipAddressStr)
public IPv4(java.lang.String ipAddressStr, java.lang.String ipMaskStr)
public IPv4 getNetAddress()
public static boolean isValidIp(java.lang.String ipAddressStr)
public long getIpLongValue()
public int getD()
public int getC()
public int getB()
public int getA()
public java.lang.String getStringA()
public java.lang.String getStringB()
public java.lang.String getStringC()
public java.lang.String getStringD()
public long getIpMask()
public boolean isNull()
public IPv4 getFirstIp()
public IPv4 getLastIp()
public boolean isIpClassA()
public boolean isIpClassB()
public boolean isIpClassC()
public java.lang.String getIpClassName()
public java.lang.String getNetClassRange()
public boolean isSingleIp()
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public boolean isSaneMask()
public IPv4 prevIP()
public IPv4 nextIP()
Documentation Feedback
Copyright 2012 Micro Focus or one of its affiliates.