|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.dspace.statistics.util.IPTable
public class IPTable
A Spare v4 IPTable implementation that uses nested HashMaps to optimize IP address matching over ranges of IP addresses.
| Nested Class Summary | |
|---|---|
static class |
IPTable.IPFormatException
Exception Class to deal with IPFormat errors. |
| Constructor Summary | |
|---|---|
IPTable()
|
|
| Method Summary | |
|---|---|
void |
add(String ip)
Can be full v4 IP, subnet or range string |
boolean |
contains(String ip)
Check whether a given address is contained in this netblock. |
Set<String> |
toSet()
Convert to a Set. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public IPTable()
| Method Detail |
|---|
public void add(String ip)
throws IPTable.IPFormatException
ip -
IPTable.IPFormatException
public boolean contains(String ip)
throws IPTable.IPFormatException
ip - the address to be tested
ip is within this table's limits
IPTable.IPFormatExceptionpublic Set<String> toSet()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||