org.dspace.statistics.util
Class IPTable

java.lang.Object
  extended by org.dspace.statistics.util.IPTable

public class IPTable
extends Object

A Spare v4 IPTable implementation that uses nested HashMaps TO optimize IP Address matching over ranges of IP Addresses.


Nested Class Summary
 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)
           
 Set<String> toSet()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IPTable

public IPTable()
Method Detail

add

public void add(String ip)
         throws IPTable.IPFormatException
Can be full v4 IP, subnet or range string

Parameters:
ip -
Throws:
IPTable.IPFormatException

contains

public boolean contains(String ip)
                 throws IPTable.IPFormatException
Throws:
IPTable.IPFormatException

toSet

public Set<String> toSet()
Returns:


Copyright © 2010 The DSpace Foundation. All Rights Reserved.