org.sat4j.csp
Interface Evaluable

All Known Implementing Classes:
Constant, Var

public interface Evaluable


Method Summary
 Domain domain()
          Return the domain of the evaluable.
 void toClause(ISolver solver)
          Translates a variable over a domain into a set a clauses enforcing that exactly one value must be chosen in the domain.
 int translate(int key)
          Translates a value from the domain into a SAT variable in Dimacs format.
 

Method Detail

domain

Domain domain()
Return the domain of the evaluable.

Returns:
the domain of the evaluable.

translate

int translate(int key)
Translates a value from the domain into a SAT variable in Dimacs format.

Parameters:
key - a value from domain()
Returns:
the SAT variable associated with that value.

toClause

void toClause(ISolver solver)
              throws ContradictionException
Translates a variable over a domain into a set a clauses enforcing that exactly one value must be chosen in the domain.

Parameters:
solver - a solver to feed with the clauses.
Throws:
ContradictionException - if a trivial inconsistency is met.


Copyright © 2010 Centre de Recherche en Informatique de Lens (CRIL). All Rights Reserved.