pumpkin_solver::predicates

Trait PredicateConstructor

source
pub trait PredicateConstructor {
    type Value;

    // Required methods
    fn lower_bound_predicate(&self, bound: Self::Value) -> Predicate;
    fn upper_bound_predicate(&self, bound: Self::Value) -> Predicate;
    fn equality_predicate(&self, bound: Self::Value) -> Predicate;
    fn disequality_predicate(&self, bound: Self::Value) -> Predicate;
}
Expand description

A trait which defines methods for creating a Predicate. It currently only specifies the creation of Predicates based on IntegerPredicates.

Required Associated Types§

source

type Value

The value used to represent a bound.

Required Methods§

source

fn lower_bound_predicate(&self, bound: Self::Value) -> Predicate

Creates a lower-bound predicate (e.g. [x >= v]).

source

fn upper_bound_predicate(&self, bound: Self::Value) -> Predicate

Creates an upper-bound predicate (e.g. [x <= v]).

source

fn equality_predicate(&self, bound: Self::Value) -> Predicate

Creates an equality predicate (e.g. [x == v]).

source

fn disequality_predicate(&self, bound: Self::Value) -> Predicate

Creates a disequality predicate (e.g. [x != v]).

Implementors§