Commit 9235c056 authored by Daniel Le Berre's avatar Daniel Le Berre

Make more objects serializable.

parent c2eb9d91
......@@ -29,6 +29,8 @@
*******************************************************************************/
package org.sat4j.specs;
import java.io.Serializable;
/**
* The aim on that interface is to allow power users to communicate with the SAT
* solver using Dimacs format. That way, there is no need to know the internals
......@@ -37,7 +39,7 @@ package org.sat4j.specs;
* @author leberre
* @since 2.3.2
*/
public interface ISolverService {
public interface ISolverService extends Serializable {
/**
* Ask the SAT solver to stop the search.
......
......@@ -29,6 +29,8 @@
*******************************************************************************/
package org.sat4j.specs;
import java.io.Serializable;
/**
* That interface allows to efficiently retrieve the truth value of a given
* variable in the solver.
......@@ -36,7 +38,7 @@ package org.sat4j.specs;
* @author daniel
*
*/
public interface RandomAccessModel {
public interface RandomAccessModel extends Serializable {
/**
* Provide the truth value of a specific variable in the model.
*
......
......@@ -29,6 +29,8 @@
*******************************************************************************/
package org.sat4j.pb.constraints;
import java.io.Serializable;
import org.sat4j.minisat.core.ILits;
import org.sat4j.pb.constraints.pb.IDataStructurePB;
import org.sat4j.specs.Constr;
......@@ -36,7 +38,7 @@ import org.sat4j.specs.ContradictionException;
import org.sat4j.specs.IVecInt;
import org.sat4j.specs.UnitPropagationListener;
public interface ICardConstructor {
public interface ICardConstructor extends Serializable {
Constr constructCard(UnitPropagationListener solver, ILits voc,
IVecInt theLits, int degree) throws ContradictionException;
......
......@@ -29,14 +29,17 @@
*******************************************************************************/
package org.sat4j.pb.constraints;
import java.io.Serializable;
import org.sat4j.minisat.core.ILits;
import org.sat4j.specs.Constr;
import org.sat4j.specs.IVecInt;
import org.sat4j.specs.UnitPropagationListener;
public interface IClauseConstructor {
public interface IClauseConstructor extends Serializable {
Constr constructClause(UnitPropagationListener solver, ILits voc, IVecInt v);
Constr constructClause(UnitPropagationListener solver, ILits voc,
IVecInt v);
Constr constructLearntClause(ILits voc, IVecInt literals);
......
......@@ -29,6 +29,7 @@
*******************************************************************************/
package org.sat4j.pb.constraints;
import java.io.Serializable;
import java.math.BigInteger;
import org.sat4j.minisat.core.ILits;
......@@ -37,12 +38,12 @@ import org.sat4j.specs.Constr;
import org.sat4j.specs.ContradictionException;
import org.sat4j.specs.UnitPropagationListener;
public interface IPBConstructor {
public interface IPBConstructor extends Serializable {
Constr constructLearntPB(ILits voc, IDataStructurePB dspb);
Constr constructPB(UnitPropagationListener solver, ILits voc,
int[] theLits, BigInteger[] coefs, BigInteger degree,
BigInteger sumCoefs) throws ContradictionException;
Constr constructPB(UnitPropagationListener solver, ILits voc, int[] theLits,
BigInteger[] coefs, BigInteger degree, BigInteger sumCoefs)
throws ContradictionException;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment