|
FRODO Version 2.19.1
An open-source framework for Distributed Constraint Optimization (DCOP)
|
Predicate wrapper that translates a predicate expression from XCSP into constraints available in JaCoP. More...

Public Member Functions | |
| Predicate (String constraintParameters, String predicateParameters, String description, StoreCloneable store) | |
| It creates/imposes constraints into the store as soon as the Predicate constraint is being imposed. | |
| String | toString () |
| ArrayList< Constraint > | decompose (Store store) throws FailException |
| PrimitiveConstraint | getConstraint (StoreCloneable store) throws FailException |
| It allows to obtain the constraint specified by the predicate without imposing it. | |
| void | imposeDecomposition (Store store) throws FailException |
| ArrayList< Var > | auxiliaryVariables () |
| List< IntVarCloneable > | arguments () |
| Predicate | cloneInto (StoreCloneable targetStore) throws CloneNotSupportedException |
| String | id () |
Package Attributes | |
| String | constraintParameters |
| The XCSP parameters of the constraint. | |
| final boolean | debug = false |
| Whether to print out debug information. | |
| String | description |
| The functional representation of the predicate. | |
| StoreCloneable | store |
| The constraint store. | |
| String | predicateParameters |
| The XCSP parameters of the predicate. | |
| ArrayList< Constraint > | decompositionConstraints |
| The auxiliary constraints created. | |
| ArrayList< Var > | auxilaryVariables |
| The auxiliary variables created. | |
| IntVarCloneable | valuationVar |
| The utility variable (if this is a soft constraint). | |
Private Member Functions | |
| Object | parse (String token, StringTokenizer tokenizer, StoreCloneable store, HashMap< String, Object > variableMaping) throws FailException |
Static Private Member Functions | |
| static IntVarCloneable | getIntVarCloneable (StoreCloneable store, String name, String name2, int minVal, int maxVal) throws FailException |
| Looks up or creates a variable in the input store. | |
| static IntVarCloneable | getIntVarCloneable (StoreCloneable store, String name, String name2, IntDomain dom) throws FailException |
| Looks up or creates a variable in the input store. | |
Predicate wrapper that translates a predicate expression from XCSP into constraints available in JaCoP.
It accepts only functional representation. Possibly, some auxiliary variables will be created.
| frodo2.solutionSpaces.JaCoP.Predicate.Predicate | ( | String | constraintParameters, |
| String | predicateParameters, | ||
| String | description, | ||
| StoreCloneable | store ) |
It creates/imposes constraints into the store as soon as the Predicate constraint is being imposed.
| constraintParameters | parameters to the constraint. |
| predicateParameters | parameters specified within a predicate definition. |
| description | description of the constraint specified as the predicate. |
| store | the constraint store in which context the constraints are being created/imposed. |
References constraintParameters, decompose(), description, predicateParameters, and store.
Referenced by cloneInto().

| List< IntVarCloneable > frodo2.solutionSpaces.JaCoP.Predicate.arguments | ( | ) |
| ArrayList< Var > frodo2.solutionSpaces.JaCoP.Predicate.auxiliaryVariables | ( | ) |
References auxilaryVariables.
| Predicate frodo2.solutionSpaces.JaCoP.Predicate.cloneInto | ( | StoreCloneable | targetStore | ) | throws CloneNotSupportedException |
Implements org.jacop.constraints.ConstraintCloneableInterface< C extends DecomposedConstraint<? extends Constraint > >.
References Predicate().

| ArrayList< Constraint > frodo2.solutionSpaces.JaCoP.Predicate.decompose | ( | Store | store | ) | throws FailException |
References auxilaryVariables, constraintParameters, debug, decompositionConstraints, description, getIntVarCloneable(), parse(), predicateParameters, and store.
Referenced by imposeDecomposition(), and Predicate().

| PrimitiveConstraint frodo2.solutionSpaces.JaCoP.Predicate.getConstraint | ( | StoreCloneable | store | ) | throws FailException |
It allows to obtain the constraint specified by the predicate without imposing it.
| store | the constraint store in which context the constraint is being created. |
| FailException | thrown if a variable with an empty domain was encountered |
References constraintParameters, debug, description, parse(), predicateParameters, and store.

|
staticprivate |
Looks up or creates a variable in the input store.
| store | the store |
| name | the name of the variable |
| name2 | another, synonymous name for the variable (if any) |
| minVal | minimum variable value |
| maxVal | maximum variable value |
| FailException | if the resulting variable domain is empty |
References getIntVarCloneable(), and store.
Referenced by decompose(), getIntVarCloneable(), and parse().

|
staticprivate |
Looks up or creates a variable in the input store.
| store | the store |
| name | the name of the variable |
| name2 | another, synonymous name for the variable (if any) |
| dom | the variable domain |
| FailException | if the resulting variable domain is empty |
References store.
| String frodo2.solutionSpaces.JaCoP.Predicate.id | ( | ) |
Implements org.jacop.constraints.DecomposedConstraintCloneableInterface.
| void frodo2.solutionSpaces.JaCoP.Predicate.imposeDecomposition | ( | Store | store | ) | throws FailException |
References auxilaryVariables, decompose(), decompositionConstraints, and store.

|
private |
| token | the current token |
| tokenizer | the tokenizer |
| store | the constraint store |
| variableMaping | a mapping from name to variable or constant |
| FailException | thrown if one of the encountered variables has an empty domain |
References auxilaryVariables, decompositionConstraints, getIntVarCloneable(), parse(), and store.
Referenced by decompose(), getConstraint(), and parse().

| String frodo2.solutionSpaces.JaCoP.Predicate.toString | ( | ) |
|
package |
The auxiliary variables created.
Referenced by auxiliaryVariables(), decompose(), imposeDecomposition(), and parse().
|
package |
The XCSP parameters of the constraint.
Referenced by decompose(), getConstraint(), and Predicate().
|
package |
Whether to print out debug information.
Referenced by decompose(), and getConstraint().
|
package |
The auxiliary constraints created.
Referenced by decompose(), imposeDecomposition(), and parse().
|
package |
The functional representation of the predicate.
Referenced by decompose(), getConstraint(), and Predicate().
|
package |
The XCSP parameters of the predicate.
Referenced by decompose(), getConstraint(), and Predicate().
|
package |
The constraint store.
Referenced by decompose(), getConstraint(), getIntVarCloneable(), getIntVarCloneable(), imposeDecomposition(), parse(), and Predicate().
|
package |
The utility variable (if this is a soft constraint).
Referenced by arguments(), and frodo2.solutionSpaces.JaCoP.JaCoPxcspParser< V extends Addable< V > >.parsePredicate().