Package ru.ispras.fortress.logic
Class Clause.Builder
- java.lang.Object
-
- ru.ispras.fortress.logic.Clause.Builder
-
- Enclosing class:
- Clause
public static final class Clause.Builder extends java.lang.Object
Clause.Builder
implements a clause builder.
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(int[] vars, boolean sign)
Appends the specified literals to the clause.void
add(int[] vars, boolean[] signs)
Appends the specified literals to the clause.void
add(int var, boolean sign)
Appends the specified literal to the clause.void
add(Clause clause)
Appends the specified clause to the clause.Clause
build()
-
-
-
Method Detail
-
add
public void add(int var, boolean sign)
Appends the specified literal to the clause.- Parameters:
var
- the variable.sign
- the negation.
-
add
public void add(int[] vars, boolean sign)
Appends the specified literals to the clause.- Parameters:
vars
- the variables.sign
- the negation (common for all variables).
-
add
public void add(int[] vars, boolean[] signs)
Appends the specified literals to the clause.- Parameters:
vars
- the variables.signs
- the negations.
-
add
public void add(Clause clause)
Appends the specified clause to the clause.- Parameters:
clause
- the clause to be added.
-
build
public Clause build()
-
-