cc.mallet.grmm.types
Class Universe

java.lang.Object
  extended by cc.mallet.grmm.types.Universe
All Implemented Interfaces:
java.io.Serializable

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

A global mapping between variables and indices. All variables belong to exactly one universe. $Id: Universe.java,v 1.1 2007/10/22 21:37:44 mccallum Exp $

See Also:
Serialized Form

Field Summary
static Universe DEFAULT
           
 
Constructor Summary
Universe()
           
 
Method Summary
 int add(Variable var)
           
 Variable get(int idx)
           
 int getIndex(Variable var)
           
 gnu.trove.TIntObjectHashMap lookupProjectionCache(VarSet varSet)
           
static void resetUniverse()
           
 int size()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT

public static Universe DEFAULT
Constructor Detail

Universe

public Universe()
Method Detail

resetUniverse

public static void resetUniverse()

add

public int add(Variable var)

get

public Variable get(int idx)

getIndex

public int getIndex(Variable var)

size

public int size()

lookupProjectionCache

public gnu.trove.TIntObjectHashMap lookupProjectionCache(VarSet varSet)