org.tfe.core
Class HotIPList

java.lang.Object
  |
  +--org.tfe.core.HotIPList
All Implemented Interfaces:
java.io.Serializable

public class HotIPList
extends java.lang.Object
implements java.io.Serializable

See Also:
Serialized Form

Constructor Summary
HotIPList()
          Creates new HotIPList
 
Method Summary
 void add(HotIP ip)
          Adds a HotIP to the list.
 void addObserver(HotIPListObserver anObserver)
           
 boolean contains(HotIP ip)
          Whether or not the list contains a specified HotIP.
 boolean contains(java.lang.String ipAddress)
          Whether or not the list contains a HotIP that has a source address that matches the specified String.
 void deleteObserver(HotIPListObserver anObserver)
           
 HotIP get(int index)
          Retrieves a HotIP from the list.
 void hotIPUpdated(HotIP ip)
          Notifies observers that a hotIP was updated.
 void remove(HotIP ip)
          Removes the specified HotIP
 void remove(int index)
          Removes the HotIP at the specified index.
 int size()
          Get the size of the Hot IP List
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HotIPList

public HotIPList()
Creates new HotIPList

Method Detail

add

public void add(HotIP ip)
Adds a HotIP to the list. This function adds a new HotIP to the list.


get

public HotIP get(int index)
Retrieves a HotIP from the list. This function retrieves the HotIP at the specified index.

Parameters:
index - the index of the HotIP to be retrieved.
Returns:
the HotIP at the specified index.

remove

public void remove(HotIP ip)
Removes the specified HotIP

Parameters:
ip - the HotIP to be removed from the list.

remove

public void remove(int index)
Removes the HotIP at the specified index.

Parameters:
index - the index of the HotIP to be removed.

hotIPUpdated

public void hotIPUpdated(HotIP ip)
Notifies observers that a hotIP was updated. Right now it is up to the programmer to invoke this method when they edit a HotIP.

Parameters:
ip - the HotIP that was edited.

contains

public boolean contains(HotIP ip)
Whether or not the list contains a specified HotIP.

Returns:
true if the list contains the HotIP, false if not.

contains

public boolean contains(java.lang.String ipAddress)
Whether or not the list contains a HotIP that has a source address that matches the specified String.

Parameters:
ipAddress - a String representation of the address for which to look.
Returns:
true if the address is found, false if not.

size

public int size()
Get the size of the Hot IP List

Returns:
the size (int) of the Hot IP list

addObserver

public void addObserver(HotIPListObserver anObserver)

deleteObserver

public void deleteObserver(HotIPListObserver anObserver)