org.jboss.portal.common.util
Class SetMap

java.lang.Object
  extended by org.jboss.portal.common.util.CollectionMap
      extended by org.jboss.portal.common.util.SetMap
All Implemented Interfaces:
java.io.Serializable

public class SetMap
extends CollectionMap

A map of set. This object does not handle synchronization and use HashMap and HashSet as underlying data structures;

Version:
$Revision: 7322 $
Author:
Julien Viet
See Also:
Serialized Form

Field Summary
protected  java.util.Comparator comparator
          An optional comparator.
 
Fields inherited from class org.jboss.portal.common.util.CollectionMap
map
 
Constructor Summary
SetMap()
           
SetMap(java.util.Comparator comparator)
           
SetMap(SetMap other)
           
SetMap(SetMap other, java.util.Comparator comparator)
           
 
Method Summary
protected  void add(java.util.Collection c, java.lang.Object o)
           
 java.util.Set get(java.lang.Object key)
          Return the set specified by the key.
protected  java.util.Collection newCollection()
           
protected  java.util.Collection newCollection(java.util.Collection other)
           
protected  void remove(java.util.Collection c, java.lang.Object o)
           
 
Methods inherited from class org.jboss.portal.common.util.CollectionMap
contains, iterator, keySet, put, remove, remove
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

comparator

protected java.util.Comparator comparator
An optional comparator.

Constructor Detail

SetMap

public SetMap()

SetMap

public SetMap(SetMap other)
       throws java.lang.IllegalArgumentException
Throws:
java.lang.IllegalArgumentException

SetMap

public SetMap(SetMap other,
              java.util.Comparator comparator)
       throws java.lang.IllegalArgumentException
Throws:
java.lang.IllegalArgumentException

SetMap

public SetMap(java.util.Comparator comparator)
Method Detail

get

public java.util.Set get(java.lang.Object key)
Return the set specified by the key.


add

protected void add(java.util.Collection c,
                   java.lang.Object o)
Specified by:
add in class CollectionMap

remove

protected void remove(java.util.Collection c,
                      java.lang.Object o)
Specified by:
remove in class CollectionMap

newCollection

protected java.util.Collection newCollection()
Specified by:
newCollection in class CollectionMap

newCollection

protected java.util.Collection newCollection(java.util.Collection other)
Specified by:
newCollection in class CollectionMap