org.jrdf.graph.mem
Class BagImpl

java.lang.Object
  extended byorg.jrdf.graph.mem.AbstractUnorderedContainer
      extended byorg.jrdf.graph.mem.BagImpl
All Implemented Interfaces:
Bag, Collection, Container

public class BagImpl
extends AbstractUnorderedContainer
implements Bag

An implementation of Bag.

Version:
$Revision: 1.1 $
Author:
Andrew Newman

Constructor Summary
BagImpl()
           
 
Method Summary
 boolean addAll(Collection c)
          
 boolean containsAll(Collection c)
          
 boolean equals(Object obj)
           
 int hashCode()
           
 boolean removeAll(Collection c)
          
 boolean retainAll(Collection c)
          
 
Methods inherited from class org.jrdf.graph.mem.AbstractUnorderedContainer
add, clear, contains, isEmpty, iterator, remove, size, toArray, toArray
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jrdf.graph.Container
add, remove
 
Methods inherited from interface java.util.Collection
clear, contains, isEmpty, iterator, size, toArray, toArray
 

Constructor Detail

BagImpl

public BagImpl()
Method Detail

containsAll

public boolean containsAll(Collection c)
Description copied from interface: Bag

Specified by:
containsAll in interface Bag
Parameters:
c -

addAll

public boolean addAll(Collection c)
               throws IllegalArgumentException
Description copied from interface: Bag

Specified by:
addAll in interface Bag
Parameters:
c -
Throws:
IllegalArgumentException - if the given object is not the correct type, Bag.

removeAll

public boolean removeAll(Collection c)
                  throws IllegalArgumentException
Description copied from interface: Bag

Specified by:
removeAll in interface Bag
Parameters:
c -
Throws:
IllegalArgumentException - if the given object is not the correct type, Bag.

retainAll

public boolean retainAll(Collection c)
                  throws IllegalArgumentException
Description copied from interface: Bag

Specified by:
retainAll in interface Bag
Parameters:
c -
Throws:
IllegalArgumentException - if the given object is not the correct type, Bag.

hashCode

public int hashCode()
Specified by:
hashCode in interface Collection
Overrides:
hashCode in class AbstractUnorderedContainer

equals

public boolean equals(Object obj)
Specified by:
equals in interface Collection
Specified by:
equals in class AbstractUnorderedContainer