- java.lang.Object
-
- org.logicng.solvers.functions.UpZeroLiteralsFunction
-
- All Implemented Interfaces:
SolverFunction<SortedSet<Literal>>
public final class UpZeroLiteralsFunction extends Object implements SolverFunction<SortedSet<Literal>>
A solver function which returns all unit propagated literals on level 0 of the current formula on the solver. If the formula is UNSAT,nullwill be returned.- Since:
- 2.0.0
- Version:
- 2.0.0
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description SortedSet<Literal>apply(MiniSat solver, Consumer<Tristate> resultSetter)Applies this function to the given solver.static UpZeroLiteralsFunctionget()Returns the singleton of the function.
-
-
-
Method Detail
-
get
public static UpZeroLiteralsFunction get()
Returns the singleton of the function.- Returns:
- the function instance
-
apply
public SortedSet<Literal> apply(MiniSat solver, Consumer<Tristate> resultSetter)
Description copied from interface:SolverFunctionApplies this function to the given solver.- Specified by:
applyin interfaceSolverFunction<SortedSet<Literal>>- Parameters:
solver- the solver on which the function should work onresultSetter- a setter for the result of the solver- Returns:
- the result of the function application
-
-