com.inxar.syntacs.util
Class HashBitSetIntRelation

java.lang.Object
  |
  +--com.inxar.syntacs.util.HashBitSetIntRelation
All Implemented Interfaces:
IntRelation

public class HashBitSetIntRelation
extends Object
implements IntRelation

Concrete implementation of IntRelation which uses a hash table such that each entry in the table contains a BitSetIntSet. IntSet, if needed.


Constructor Summary
HashBitSetIntRelation()
          Constructs the HashBitSetIntRelation with a default initial capacity.
HashBitSetIntRelation(int capacity)
          Constructs the HashBitSetIntRelation with the given initial capacity.
 
Method Summary
 IntSet get(int key)
          Returns the set under the given key.
 boolean isEmpty()
          Returns true if the set of keys is the empty set.
 IntSet keys()
          Returns the set of keys.
 void put(int key, int value)
          Puts the given value in the set under the given key.
 Reiterator reiterator()
          Returns a Reiterator view.
 void set(int key, IntSet values)
          Assigns the given set to the given key.
 String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

HashBitSetIntRelation

public HashBitSetIntRelation(int capacity)
Constructs the HashBitSetIntRelation with the given initial capacity.

HashBitSetIntRelation

public HashBitSetIntRelation()
Constructs the HashBitSetIntRelation with a default initial capacity.
Method Detail

get

public IntSet get(int key)
Description copied from interface: IntRelation
Returns the set under the given key.
Specified by:
get in interface IntRelation

set

public void set(int key,
                IntSet values)
Description copied from interface: IntRelation
Assigns the given set to the given key.
Specified by:
set in interface IntRelation

put

public void put(int key,
                int value)
Description copied from interface: IntRelation
Puts the given value in the set under the given key.
Specified by:
put in interface IntRelation

keys

public IntSet keys()
Description copied from interface: IntRelation
Returns the set of keys.
Specified by:
keys in interface IntRelation

reiterator

public Reiterator reiterator()
Description copied from interface: IntRelation
Returns a Reiterator view.
Specified by:
reiterator in interface IntRelation

isEmpty

public boolean isEmpty()
Description copied from interface: IntRelation
Returns true if the set of keys is the empty set.
Specified by:
isEmpty in interface IntRelation

toString

public String toString()
Overrides:
toString in class Object