|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.newisys.randsolver.Solver
public class Solver
The Jove random constraint solver.
| Field Summary | |
|---|---|
static com.newisys.langschema.constraint.ConsSchema |
schema
|
| Constructor Summary | |
|---|---|
Solver(com.newisys.randsolver.RandInfo randInfo)
|
|
| Method Summary | ||
|---|---|---|
static void |
disableAllConstraints(Object o)
Disables all constraints for the specified Object instance. |
|
static void |
disableAllRand(Object o)
Disables all random variables for the specified Object instance. |
|
static boolean |
disableConstraint(Object o,
String constraintName)
Disables the specified constraint for the specified Object instance. |
|
static boolean |
disableRand(Object o,
String varName)
Disables the specified random variable for the specified Object instance. |
|
static void |
enableAllConstraints(Object o)
Enables all constraints for the specified Object instance. |
|
static void |
enableAllRand(Object o)
Enables all random variables for the specified Object instance. |
|
static boolean |
enableConstraint(Object o,
String constraintName)
Enables the specified constraint for the specified Object instance. |
|
static boolean |
enableRand(Object o,
String varName)
Enables the specified random variable for the specified Object instance. |
|
void |
execute(Object obj,
com.newisys.randsolver.RandInfo rInfo,
PRNG randomStream)
|
|
static boolean |
isConstraintEnabled(Object o,
String constraintName)
Returns whether or not the specified constraint will be used when the specified object is randomized. |
|
static boolean |
isRandEnabled(Object o,
String varName)
Returns whether or not the specified random variable will be randomized when the specified object is randomized. |
|
static void |
randomize(Object obj,
PRNG randomStream)
|
|
static
|
randomizeEnumType(Class<E> enumType,
PRNG randomStream)
Returns a random instance of the specified enumeration. |
|
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final com.newisys.langschema.constraint.ConsSchema schema
| Constructor Detail |
|---|
public Solver(com.newisys.randsolver.RandInfo randInfo)
| Method Detail |
|---|
public static <E extends Enum<E>> E randomizeEnumType(Class<E> enumType,
PRNG randomStream)
RandExclude annotations included in the enumeration.
E - the enumeration type to randomizeenumType - the enumeration type to randomizerandomStream - the PRNG to use when randomizing
enumType
public static void randomize(Object obj,
PRNG randomStream)
public void execute(Object obj,
com.newisys.randsolver.RandInfo rInfo,
PRNG randomStream)
public static boolean isRandEnabled(Object o,
String varName)
true is returned. Otherwise false
is returned.
o - the object containing the random variablevarName - the name of the variable to check
true if the variable is enabled, false
otherwisepublic static void enableAllRand(Object o)
Rand or Randc will be enabled.
o - the Object instance in which to enable all random variables
public static boolean enableRand(Object o,
String varName)
o - the Object instance in which to enable the random variablevarName - a String containing the name of the variable to enable in
o
true if the variable was enabled prior to enableRand
being called, false otherwise.
InvalidRandomVarException - if varName doesn't exist in
opublic static void disableAllRand(Object o)
Rand or Randc will be disabled.
o - the Object instance in which to disable all random variables
public static boolean disableRand(Object o,
String varName)
o - the Object instance in which to disable the random variablevarName - a String containing the name of the variable to disable in
o
true if the variable was disabled prior to disableRand
being called, false otherwise.
InvalidRandomVarException - if varName doesn't exist in
o
public static boolean isConstraintEnabled(Object o,
String constraintName)
true is returned. Otherwise false
is returned.
o - the object containing the constraintconstraintName - the name of the constraint to check
true if the constraint is enabled, false
otherwisepublic static void enableAllConstraints(Object o)
Constraint
will be enabled.
o - the Object instance in which to enable all constraints
public static boolean enableConstraint(Object o,
String constraintName)
Constraint annotations.
o - the Object instance in which to enable the constraintconstraintName - a String containing the name of the constraint to enable in
o
true if the constraint was enabled prior to
enableConstraint being called, false otherwise.
InvalidConstraintException - if constraintName doesn't exist in
opublic static void disableAllConstraints(Object o)
Constraint
will be disabled.
o - the Object instance in which to disable all constraints
public static boolean disableConstraint(Object o,
String constraintName)
Constraint annotations.
o - the Object instance in which to disable the constraintconstraintName - a String containing the name of the constraint to disable in
o
true if the constraint was disabled prior to
disableConstraint being called, false otherwise.
InvalidConstraintException - if constraintName doesn't exist in
o
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||