blog
Class GenericObject

java.lang.Object
  extended by blog.GenericObject
Direct Known Subclasses:
GenericPOPAppSatisfier

public class GenericObject
extends java.lang.Object

Represents a generic object of some type, possibly with constraints on the values of its origin functions. Origin functions can be evaluated on these objects, but other functions can't. These objects cannot be used as an argument for any instantiated random variable.


Constructor Summary
GenericObject(Type type)
          Creates a new generic object of the given type, with no constraints on its generating functions.
 
Method Summary
 java.lang.Object getOriginFuncValue(OriginFunction g)
          Returns null if the value of g on this object is not determined.
 Type getType()
           
 boolean isConsistentInContext(EvalContext context, java.lang.Object obj)
          Returns true if the given object satisfies the origin function constraints imposed by this GenericObject, in the given context.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

GenericObject

public GenericObject(Type type)
Creates a new generic object of the given type, with no constraints on its generating functions.

Method Detail

getType

public Type getType()

getOriginFuncValue

public java.lang.Object getOriginFuncValue(OriginFunction g)
Returns null if the value of g on this object is not determined.


isConsistentInContext

public boolean isConsistentInContext(EvalContext context,
                                     java.lang.Object obj)
Returns true if the given object satisfies the origin function constraints imposed by this GenericObject, in the given context.


toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object