Generated on for Gecode by doxygen 1.17.0
Test::Int::Test Class Referenceabstract

Base class for tests with integer constraints More...

#include <test/int.hh>

Protected Attributes

int arity
 Number of variables.
Gecode::IntSet dom
 Domain of variables.
bool reified
 Does the constraint also exist as reified constraint.
int rms
 Supported reification modes, encoded as a bit mask of 1 << Gecode::RM_*.
Gecode::IntPropLevel ipl
 Propagation level.
ConTestLevel contest
 Whether to test for certain consistency.
bool testsearch
 Whether to perform search test.
bool testfix
 Whether to perform fixpoint test.

Test for reification modes

bool eqv (void) const
 Test whether equivalence as reification mode is supported.
bool imp (void) const
 Test whether implication as reification mode is supported.
bool pmi (void) const
 Test whether reverse implication as reification mode is supported.
 Test (const std::string &p, const std::string &s, int a, const Gecode::IntSet &d, bool r=false, Gecode::IntPropLevel i=Gecode::IPL_DEF)
 Constructor.
 Test (TestTags tags, const std::string &p, const std::string &s, int a, const Gecode::IntSet &d, bool r=false, Gecode::IntPropLevel i=Gecode::IPL_DEF)
 Construct and register a test with explicitly assigned tags.
 Test (const std::string &s, int a, const Gecode::IntSet &d, bool r=false, Gecode::IntPropLevel i=Gecode::IPL_DEF)
 Constructor.
 Test (TestTags tags, const std::string &s, int a, const Gecode::IntSet &d, bool r=false, Gecode::IntPropLevel i=Gecode::IPL_DEF)
 Construct and register a test with explicitly assigned tags.
 Test (const std::string &p, const std::string &s, int a, int min, int max, bool r=false, Gecode::IntPropLevel i=Gecode::IPL_DEF)
 Constructor.
 Test (TestTags tags, const std::string &p, const std::string &s, int a, int min, int max, bool r=false, Gecode::IntPropLevel i=Gecode::IPL_DEF)
 Construct and register a test with explicitly assigned tags.
 Test (const std::string &s, int a, int min, int max, bool r=false, Gecode::IntPropLevel i=Gecode::IPL_DEF)
 Constructor.
 Test (TestTags tags, const std::string &s, int a, int min, int max, bool r=false, Gecode::IntPropLevel i=Gecode::IPL_DEF)
 Construct and register a test with explicitly assigned tags.
virtual Assignment * assignment (void) const
 Create the assignment generator (complete by default).
virtual bool solution (const Assignment &) const =0
 Check for solution.
virtual bool ignore (const Assignment &) const
 Whether to ignore assignment for reification.
virtual void post (Gecode::Space &home, Gecode::IntVarArray &x)=0
 Post constraint.
virtual void post (Gecode::Space &home, Gecode::IntVarArray &x, Gecode::Reify r)
 Post reified constraint.
virtual bool run (void)
 Perform test.

Mapping scalar values to strings

static std::string str (bool b)
 Map bool to string.
static std::string str (int i)
 Map integer to string.
static std::string str (const Gecode::IntArgs &i)
 Map integer array to string.
static std::string str (Gecode::IntPropLevel ipl)
 Map integer propagation level to string.
static std::string str (Gecode::IntRelType irl)
 Map integer relation to string.
static std::string str (Gecode::BoolOpType bot)
 Map Boolean operation to string.

General support

template<class T>
static bool cmp (T x, Gecode::IntRelType r, T y)
 Compare x and y with respect to r.

Additional Inherited Members

Public Member Functions inherited from Test::Base
 Base (std::string s)
 Create and register a standard test with name s.
 Base (std::string s, TestTags t)
 Create and register test with name s and tags t.
const std::string & name (void) const
 Return name of test.
TestTags tags (void) const
 Return tags for test.
Base * next (void) const
 Return next test.
void next (Base *n)
 Set next test.
bool fixpoint (void)
 Throw a coin whether to compute a fixpoint.
virtual ~Base (void)
 Destructor.
Static Public Member Functions inherited from Test::Base
static void sort (void)
 Sort tests alphabetically.
static Base * tests (void)
 Return all tests.
static bool fixpoint (Gecode::Support::RandomGenerator &rand)
 Throw a coin whether to compute a fixpoint.
static std::string str (bool b)
 Map bool to string.
static std::string str (int i)
 Map integer to string.
static std::string str (const Gecode::IntArgs &i)
 Map integer array to string.
Gecode::Support::RandomGenerator _rand
 Random number generator.

Detailed Description

Base class for tests with integer constraints

Override solution() with an independent predicate over complete assignments and post() with the propagator's public posting function. The harness compares them while exercising propagation, cloning, pruning, and search. Register a test with static lifetime:

#include <test/int.hh>
class EqualityTest : public ::Test::Int::Test {
public:
EqualityTest() : ::Test::Int::Test("Package::Equality", 2, 0, 1) {}
bool solution(const ::Test::Int::Assignment& a) const override {
return a[0] == a[1];
}
void post(Gecode::Space& home, Gecode::IntVarArray& x) override {
Gecode::rel(home, x[0], Gecode::IRT_EQ, x[1]);
}
} equality_test;
int main(int argc, char* argv[]) {
return Test::run_registered_tests(argc, argv);
}
Integer variable array.
Definition int.hh:792
Computation spaces.
Definition core.hpp:1787
int run_registered_tests(int argc, char *argv[])
Run the tests in the process-wide registry.
Definition test.cpp:603
Base class for tests with integer constraints
Definition int.hh:270
void rel(Home home, FloatVar x0, FloatRelType frt, FloatVar x1)
Post propagator for .
Definition rel.cpp:68
@ IRT_EQ
Equality ( ).
Definition int.hh:1226
int main(void)
Definition main.cpp:15
Testing finite domain integers.
Definition int.cpp:41
General test support.
Definition afc.cpp:41

All test variables start with the constructor's common domain. For per-variable restrictions, post them with the constraint and include them in solution(). Use the complete assignment generator when checking the full relation.

IPL_DOM initializes contest to CTL_DOMAIN; other levels initialize it to CTL_NONE. Set contest to CTL_BOUNDS_D or CTL_BOUNDS_Z only when the propagator promises that consistency. For reified constraints, enable reification in the constructor and override the reified post().

See also
Test::run_registered_tests

Definition at line 270 of file int.hh.

Constructor & Destructor Documentation

◆ Test() [1/8]

Test::Int::Test::Test ( const std::string & p,
const std::string & s,
int a,
const Gecode::IntSet & d,
bool r = false,
Gecode::IntPropLevel i = Gecode::IPL_DEF )
inline

Constructor.

Constructs a test with prefix p, name s, arity a, and variable domain d. Also tests for a reified constraint, if r is true. The propagation level also selects the initial consistency check (see class documentation).

Definition at line 175 of file int.hpp.

◆ Test() [2/8]

Test::Int::Test::Test ( TestTags tags,
const std::string & p,
const std::string & s,
int a,
const Gecode::IntSet & d,
bool r = false,
Gecode::IntPropLevel i = Gecode::IPL_DEF )
inline

Construct and register a test with explicitly assigned tags.

Definition at line 164 of file int.hpp.

◆ Test() [3/8]

Test::Int::Test::Test ( const std::string & s,
int a,
const Gecode::IntSet & d,
bool r = false,
Gecode::IntPropLevel i = Gecode::IPL_DEF )
inline

Constructor.

Constructs a test with name s, arity a, and variable domain d. Also tests for a reified constraint, if r is true. The propagation level also selects the initial consistency check (see class documentation).

Definition at line 192 of file int.hpp.

◆ Test() [4/8]

Test::Int::Test::Test ( TestTags tags,
const std::string & s,
int a,
const Gecode::IntSet & d,
bool r = false,
Gecode::IntPropLevel i = Gecode::IPL_DEF )
inline

Construct and register a test with explicitly assigned tags.

Definition at line 181 of file int.hpp.

◆ Test() [5/8]

Test::Int::Test::Test ( const std::string & p,
const std::string & s,
int a,
int min,
int max,
bool r = false,
Gecode::IntPropLevel i = Gecode::IPL_DEF )
inline

Constructor.

Constructs a test with prefix p, name s, arity a, and variable domain min ... max. Also tests for a reified constraint, if r is true. The propagation level also selects the initial consistency check (see class documentation).

Definition at line 209 of file int.hpp.

◆ Test() [6/8]

Test::Int::Test::Test ( TestTags tags,
const std::string & p,
const std::string & s,
int a,
int min,
int max,
bool r = false,
Gecode::IntPropLevel i = Gecode::IPL_DEF )
inline

Construct and register a test with explicitly assigned tags.

Definition at line 198 of file int.hpp.

◆ Test() [7/8]

Test::Int::Test::Test ( const std::string & s,
int a,
int min,
int max,
bool r = false,
Gecode::IntPropLevel i = Gecode::IPL_DEF )
inline

Constructor.

Constructs a test with name s, arity a, variable domain min ... max. Also tests for a reified constraint, if r is true. The propagation level also selects the initial consistency check (see class documentation).

Definition at line 225 of file int.hpp.

◆ Test() [8/8]

Test::Int::Test::Test ( TestTags tags,
const std::string & s,
int a,
int min,
int max,
bool r = false,
Gecode::IntPropLevel i = Gecode::IPL_DEF )
inline

Construct and register a test with explicitly assigned tags.

Definition at line 215 of file int.hpp.

Member Function Documentation

◆ eqv()

bool Test::Int::Test::eqv ( void ) const
inlineprotected

Test whether equivalence as reification mode is supported.

Definition at line 152 of file int.hpp.

◆ imp()

bool Test::Int::Test::imp ( void ) const
inlineprotected

Test whether implication as reification mode is supported.

Definition at line 156 of file int.hpp.

◆ pmi()

bool Test::Int::Test::pmi ( void ) const
inlineprotected

Test whether reverse implication as reification mode is supported.

Definition at line 160 of file int.hpp.

◆ assignment()

◆ solution()

virtual bool Test::Int::Test::solution ( const Assignment & ) const
pure virtual

Check for solution.

Implemented in Test::Float::MiniModelLin::LinExpr, Test::Float::MiniModelLin::LinRel, Test::Int::Arithmetic::AbsXX, Test::Int::Arithmetic::AbsXY, Test::Int::Arithmetic::ArgMax, Test::Int::Arithmetic::ArgMaxBool, Test::Int::Arithmetic::ArgMaxBoolShared, Test::Int::Arithmetic::ArgMaxShared, Test::Int::Arithmetic::ArgMin, Test::Int::Arithmetic::ArgMinBool, Test::Int::Arithmetic::ArgMinBoolShared, Test::Int::Arithmetic::ArgMinShared, Test::Int::Arithmetic::Div, Test::Int::Arithmetic::DividesXX, Test::Int::Arithmetic::DividesXY, Test::Int::Arithmetic::DivMod, Test::Int::Arithmetic::GcdXXX, Test::Int::Arithmetic::GcdXXY, Test::Int::Arithmetic::GcdXYX, Test::Int::Arithmetic::GcdXYZ, Test::Int::Arithmetic::MaxNary, Test::Int::Arithmetic::MaxNaryShared, Test::Int::Arithmetic::MaxXXX, Test::Int::Arithmetic::MaxXXY, Test::Int::Arithmetic::MaxXYX, Test::Int::Arithmetic::MaxXYY, Test::Int::Arithmetic::MaxXYZ, Test::Int::Arithmetic::MinNary, Test::Int::Arithmetic::MinNaryShared, Test::Int::Arithmetic::MinXXX, Test::Int::Arithmetic::MinXXY, Test::Int::Arithmetic::MinXYX, Test::Int::Arithmetic::MinXYY, Test::Int::Arithmetic::MinXYZ, Test::Int::Arithmetic::Mod, Test::Int::Arithmetic::MultXXX, Test::Int::Arithmetic::MultXXY, Test::Int::Arithmetic::MultXYX, Test::Int::Arithmetic::MultXYY, Test::Int::Arithmetic::MultXYZ, Test::Int::Arithmetic::NrootXX, Test::Int::Arithmetic::NrootXY, Test::Int::Arithmetic::PowXX, Test::Int::Arithmetic::PowXY, Test::Int::Arithmetic::ProductEmpty, Test::Int::Arithmetic::ProductInterleaved, Test::Int::Arithmetic::ProductModCoefficient, Test::Int::Arithmetic::ProductModEmpty, Test::Int::Arithmetic::ProductModFolded, Test::Int::Arithmetic::ProductModLimits, Test::Int::Arithmetic::ProductModSingleton, Test::Int::Arithmetic::ProductModVarEmpty, Test::Int::Arithmetic::ProductModVarFactorResultAlias, Test::Int::Arithmetic::ProductModVarInactive, Test::Int::Arithmetic::ProductModVarModFactorAlias, Test::Int::Arithmetic::ProductModVarModResultAlias, Test::Int::Arithmetic::ProductModVarRepeated, Test::Int::Arithmetic::ProductModVarSingleton, Test::Int::Arithmetic::ProductModVarXYMR, Test::Int::Arithmetic::ProductModXXYAlias, Test::Int::Arithmetic::ProductModXYZR, Test::Int::Arithmetic::ProductSingleton, Test::Int::Arithmetic::ProductXXYAlias, Test::Int::Arithmetic::ProductXYZR, Test::Int::Arithmetic::SqrtXX, Test::Int::Arithmetic::SqrtXY, Test::Int::Arithmetic::SqrXX, Test::Int::Arithmetic::SqrXY, Test::Int::Basic::Basic, Test::Int::BinPacking::BPT, Test::Int::BinPacking::DFFLargeWeights, Test::Int::BinPacking::MBPT, Test::Int::Bool::BinConstXX, Test::Int::Bool::BinConstXY, Test::Int::Bool::BinXXX, Test::Int::Bool::BinXXY, Test::Int::Bool::BinXYX, Test::Int::Bool::BinXYY, Test::Int::Bool::BinXYZ, Test::Int::Bool::ClauseConst, Test::Int::Bool::ClauseXXY, Test::Int::Bool::ClauseXXYYX, Test::Int::Bool::ClauseXYZ, Test::Int::Bool::ITEBool, Test::Int::Bool::ITEInt, Test::Int::Bool::Nary, Test::Int::Bool::NaryConst, Test::Int::Bool::NaryShared, Test::Int::Channel::ChannelFull, Test::Int::Channel::ChannelHalf, Test::Int::Channel::ChannelLinkMulti, Test::Int::Channel::ChannelLinkSingle, Test::Int::Channel::ChannelShared, Test::Int::Circuit::Circuit, Test::Int::Circuit::CircuitCost, Test::Int::Circuit::CircuitFullCost, Test::Int::Circuit::Path, Test::Int::Circuit::PathCost, Test::Int::Count::IntArrayInt, Test::Int::Count::IntArrayVar, Test::Int::Count::IntInt, Test::Int::Count::IntIntDup, Test::Int::Count::IntVar, Test::Int::Count::IntVarShared, Test::Int::Count::SetInt, Test::Int::Count::SetVar, Test::Int::Count::VarInt, Test::Int::Count::VarVar, Test::Int::Count::VarVarSharedA, Test::Int::Count::VarVarSharedB, Test::Int::Count::VarVarSharedC, Test::Int::Cumulative::ManFixECumulative, Test::Int::Cumulative::ManFixPCumulative, Test::Int::Cumulative::ManFlexCumulative, Test::Int::Cumulative::OptFixPCumulative, Test::Int::Cumulative::OptFlexCumulative, Test::Int::Cumulatives::Cumulatives, Test::Int::Cumulatives::EmptyProfile, Test::Int::Distinct::Distinct< useCount >, Test::Int::Distinct::Except, Test::Int::Distinct::Offset, Test::Int::Distinct::Optional, Test::Int::Distinct::Random, Test::Int::Dom::DomDom, Test::Int::Dom::DomInt, Test::Int::Dom::DomRange, Test::Int::Dom::DomRangeEmpty, Test::Int::Element::IntBoolInt, Test::Int::Element::IntBoolVar, Test::Int::Element::IntIntInt, Test::Int::Element::IntIntShared, Test::Int::Element::IntIntVar, Test::Int::Element::MatrixBoolVarBoolVarXX, Test::Int::Element::MatrixBoolVarBoolVarXY, Test::Int::Element::MatrixIntBoolVarXX, Test::Int::Element::MatrixIntBoolVarXY, Test::Int::Element::MatrixIntIntVarXX, Test::Int::Element::MatrixIntIntVarXY, Test::Int::Element::MatrixIntVarIntVarXX, Test::Int::Element::MatrixIntVarIntVarXY, Test::Int::Element::VarBoolInt, Test::Int::Element::VarBoolVar, Test::Int::Element::VarIntInt, Test::Int::Element::VarIntShared, Test::Int::Element::VarIntVar, Test::Int::Exec::BoolWait, Test::Int::Exec::IntWait, Test::Int::Exec::When, Test::Int::Extensional::OpenRegularClosed, Test::Int::Extensional::OpenRegularEmpty, Test::Int::Extensional::RegAcyclicReconvergence, Test::Int::Extensional::RegBoolCyclicFrontier, Test::Int::Extensional::RegCyclicFrontier, Test::Int::Extensional::RegDistinct, Test::Int::Extensional::RegDuplicateFinals, Test::Int::Extensional::RegEmptyDFA, Test::Int::Extensional::RegEmptyREG, Test::Int::Extensional::RegNFAPrefix, Test::Int::Extensional::RegNoAcceptingPath, Test::Int::Extensional::RegOpt, Test::Int::Extensional::RegPositionDomainPruning, Test::Int::Extensional::RegRandomDifferential, Test::Int::Extensional::RegRandomNFADifferential, Test::Int::Extensional::RegRoland, Test::Int::Extensional::RegSharedA, Test::Int::Extensional::RegSharedB, Test::Int::Extensional::RegSharedC, Test::Int::Extensional::RegSharedD, Test::Int::Extensional::RegSimpleA, Test::Int::Extensional::RegSimpleB, Test::Int::Extensional::RegSimpleC, Test::Int::Extensional::RegSparseStateNumbering, Test::Int::Extensional::RegTerminalMerged, Test::Int::Extensional::RegTerminalUnmerged, Test::Int::Extensional::SparseTupleSet, Test::Int::Extensional::SparseTupleSetIncremental, Test::Int::Extensional::SparseTupleSetNullary, Test::Int::Extensional::TupleSetBase, Test::Int::Extensional::TupleSetBool, Test::Int::Extensional::TupleSetLarge, Test::Int::Extensional::TupleSetTest, Test::Int::GCC::IntAllMax, Test::Int::GCC::IntAllMinMax, Test::Int::GCC::IntAllMinMaxDef, Test::Int::GCC::IntSome< hole >, Test::Int::GCC::VarAll, Test::Int::GCC::VarSome, Test::Int::InterDistance::Distance, Test::Int::InterDistance::Examples, Test::Int::InterDistance::Random, Test::Int::InterDistance::Variable, Test::Int::Linear::BoolInt, Test::Int::Linear::BoolVar, Test::Int::Linear::IntInt, Test::Int::Linear::IntVar, Test::Int::Member::Bool, Test::Int::Member::Int, Test::Int::MinDistance::Minimum, Test::Int::MiniModel::BoolLex, Test::Int::MiniModel::IntLex, Test::Int::MiniModelArithmetic::Abs, Test::Int::MiniModelArithmetic::Div, Test::Int::MiniModelArithmetic::Max, Test::Int::MiniModelArithmetic::MaxNary, Test::Int::MiniModelArithmetic::Min, Test::Int::MiniModelArithmetic::MinNary, Test::Int::MiniModelArithmetic::Minus, Test::Int::MiniModelArithmetic::Mod, Test::Int::MiniModelArithmetic::Mult, Test::Int::MiniModelArithmetic::Plus, Test::Int::MiniModelArithmetic::Sqr, Test::Int::MiniModelArithmetic::Sqrt, Test::Int::MiniModelBoolean::BoolElement, Test::Int::MiniModelBoolean::BoolExprConstant, Test::Int::MiniModelBoolean::BoolExprDefaultAccumulator, Test::Int::MiniModelBoolean::BoolExprInt, Test::Int::MiniModelBoolean::BoolExprInvalid, Test::Int::MiniModelBoolean::BoolExprVar, Test::Int::MiniModelCount::IntArrayInt, Test::Int::MiniModelCount::IntArrayVar, Test::Int::MiniModelCount::IntInt, Test::Int::MiniModelCount::IntVar, Test::Int::MiniModelCount::VarInt, Test::Int::MiniModelCount::VarVar, Test::Int::MiniModelLin::LinExprBool, Test::Int::MiniModelLin::LinExprDefault, Test::Int::MiniModelLin::LinExprInt, Test::Int::MiniModelLin::LinExprMixed, Test::Int::MiniModelLin::LinRelBool, Test::Int::MiniModelLin::LinRelInt, Test::Int::MiniModelLin::LinRelMixed, Test::Int::MiniModelSet::SetExprConst, Test::Int::MiniModelSet::SetExprExpr, Test::Int::NoOverlap::Int2, Test::Int::NoOverlap::IntOpt2, Test::Int::NoOverlap::Var2, Test::Int::NoOverlap::VarOpt2, Test::Int::NoOverlap::VarOptShared2, Test::Int::NValues::BoolInt, Test::Int::NValues::BoolVar, Test::Int::NValues::IntInt, Test::Int::NValues::IntVar, Test::Int::OpenList::Constraint, Test::Int::OpenList::EmptyMinimum, Test::Int::OpenList::Extremum, Test::Int::Order::Int, Test::Int::Precede::Multi, Test::Int::Precede::Single, Test::Int::Rel::BoolArrayInt, Test::Int::Rel::BoolArrayVar, Test::Int::Rel::BoolInt, Test::Int::Rel::BoolSeq, Test::Int::Rel::BoolSharedSeq, Test::Int::Rel::BoolVarXX, Test::Int::Rel::BoolVarXY, Test::Int::Rel::IntArrayDiff, Test::Int::Rel::IntArrayInt, Test::Int::Rel::IntArrayVar, Test::Int::Rel::IntInt, Test::Int::Rel::IntSeq, Test::Int::Rel::IntSharedSeq, Test::Int::Rel::IntVarXX, Test::Int::Rel::IntVarXY, Test::Int::Sequence::SequenceTest, Test::Int::Sorted::NoVar, Test::Int::Sorted::PermVar, Test::Int::Unary::ManFixPUnary, Test::Int::Unary::ManFlexUnary, Test::Int::Unary::OptFixPUnary, Test::Int::Unary::OptFlexUnary, Test::Int::Unshare::Bool, Test::Int::Unshare::Failed, and Test::Int::Unshare::Int.

◆ ignore()

bool Test::Int::Test::ignore ( const Assignment & ) const
virtual

Whether to ignore assignment for reification.

Reimplemented in Test::Int::Linear::BoolVar.

Definition at line 472 of file int.cpp.

◆ post() [1/2]

virtual void Test::Int::Test::post ( Gecode::Space & home,
Gecode::IntVarArray & x )
pure virtual

Post constraint.

Implemented in Test::Float::MiniModelLin::LinExpr, Test::Float::MiniModelLin::LinRel, Test::Int::Arithmetic::AbsXX, Test::Int::Arithmetic::AbsXY, Test::Int::Arithmetic::ArgMax, Test::Int::Arithmetic::ArgMaxBool, Test::Int::Arithmetic::ArgMaxBoolShared, Test::Int::Arithmetic::ArgMaxShared, Test::Int::Arithmetic::ArgMin, Test::Int::Arithmetic::ArgMinBool, Test::Int::Arithmetic::ArgMinBoolShared, Test::Int::Arithmetic::ArgMinShared, Test::Int::Arithmetic::Div, Test::Int::Arithmetic::DividesXX, Test::Int::Arithmetic::DividesXY, Test::Int::Arithmetic::DivMod, Test::Int::Arithmetic::GcdXXX, Test::Int::Arithmetic::GcdXXY, Test::Int::Arithmetic::GcdXYX, Test::Int::Arithmetic::GcdXYZ, Test::Int::Arithmetic::MaxNary, Test::Int::Arithmetic::MaxNaryShared, Test::Int::Arithmetic::MaxXXX, Test::Int::Arithmetic::MaxXXY, Test::Int::Arithmetic::MaxXYX, Test::Int::Arithmetic::MaxXYY, Test::Int::Arithmetic::MaxXYZ, Test::Int::Arithmetic::MinNary, Test::Int::Arithmetic::MinNaryShared, Test::Int::Arithmetic::MinXXX, Test::Int::Arithmetic::MinXXY, Test::Int::Arithmetic::MinXYX, Test::Int::Arithmetic::MinXYY, Test::Int::Arithmetic::MinXYZ, Test::Int::Arithmetic::Mod, Test::Int::Arithmetic::MultXXX, Test::Int::Arithmetic::MultXXY, Test::Int::Arithmetic::MultXYX, Test::Int::Arithmetic::MultXYY, Test::Int::Arithmetic::MultXYZ, Test::Int::Arithmetic::NrootXX, Test::Int::Arithmetic::NrootXY, Test::Int::Arithmetic::PowXX, Test::Int::Arithmetic::PowXY, Test::Int::Arithmetic::ProductEmpty, Test::Int::Arithmetic::ProductInterleaved, Test::Int::Arithmetic::ProductModCoefficient, Test::Int::Arithmetic::ProductModEmpty, Test::Int::Arithmetic::ProductModFolded, Test::Int::Arithmetic::ProductModLimits, Test::Int::Arithmetic::ProductModSingleton, Test::Int::Arithmetic::ProductModVarEmpty, Test::Int::Arithmetic::ProductModVarFactorResultAlias, Test::Int::Arithmetic::ProductModVarInactive, Test::Int::Arithmetic::ProductModVarModFactorAlias, Test::Int::Arithmetic::ProductModVarModResultAlias, Test::Int::Arithmetic::ProductModVarRepeated, Test::Int::Arithmetic::ProductModVarSingleton, Test::Int::Arithmetic::ProductModVarXYMR, Test::Int::Arithmetic::ProductModXXYAlias, Test::Int::Arithmetic::ProductModXYZR, Test::Int::Arithmetic::ProductSingleton, Test::Int::Arithmetic::ProductXXYAlias, Test::Int::Arithmetic::ProductXYZR, Test::Int::Arithmetic::SqrtXX, Test::Int::Arithmetic::SqrtXY, Test::Int::Arithmetic::SqrXX, Test::Int::Arithmetic::SqrXY, Test::Int::Basic::Basic, Test::Int::BinPacking::BPT, Test::Int::BinPacking::DFFLargeWeights, Test::Int::BinPacking::MBPT, Test::Int::Bool::BinConstXX, Test::Int::Bool::BinConstXY, Test::Int::Bool::BinXXX, Test::Int::Bool::BinXXY, Test::Int::Bool::BinXYX, Test::Int::Bool::BinXYY, Test::Int::Bool::BinXYZ, Test::Int::Bool::ClauseConst, Test::Int::Bool::ClauseXXY, Test::Int::Bool::ClauseXXYYX, Test::Int::Bool::ClauseXYZ, Test::Int::Bool::ITEBool, Test::Int::Bool::ITEInt, Test::Int::Bool::Nary, Test::Int::Bool::NaryConst, Test::Int::Bool::NaryShared, Test::Int::Channel::ChannelFull, Test::Int::Channel::ChannelHalf, Test::Int::Channel::ChannelLinkMulti, Test::Int::Channel::ChannelLinkSingle, Test::Int::Channel::ChannelShared, Test::Int::Circuit::Circuit, Test::Int::Circuit::CircuitCost, Test::Int::Circuit::CircuitFullCost, Test::Int::Circuit::Path, Test::Int::Circuit::PathCost, Test::Int::Count::IntArrayInt, Test::Int::Count::IntArrayVar, Test::Int::Count::IntInt, Test::Int::Count::IntIntDup, Test::Int::Count::IntVar, Test::Int::Count::IntVarShared, Test::Int::Count::SetInt, Test::Int::Count::SetVar, Test::Int::Count::VarInt, Test::Int::Count::VarVar, Test::Int::Count::VarVarSharedA, Test::Int::Count::VarVarSharedB, Test::Int::Count::VarVarSharedC, Test::Int::Cumulative::ManFixECumulative, Test::Int::Cumulative::ManFixPCumulative, Test::Int::Cumulative::ManFlexCumulative, Test::Int::Cumulative::OptFixPCumulative, Test::Int::Cumulative::OptFlexCumulative, Test::Int::Cumulatives::Cumulatives, Test::Int::Cumulatives::EmptyProfile, Test::Int::Distinct::Distinct< useCount >, Test::Int::Distinct::Except, Test::Int::Distinct::Offset, Test::Int::Distinct::Optional, Test::Int::Distinct::Random, Test::Int::Dom::DomDom, Test::Int::Dom::DomInt, Test::Int::Dom::DomRange, Test::Int::Dom::DomRangeEmpty, Test::Int::Element::IntBoolInt, Test::Int::Element::IntBoolVar, Test::Int::Element::IntIntInt, Test::Int::Element::IntIntShared, Test::Int::Element::IntIntVar, Test::Int::Element::MatrixBoolVarBoolVarXX, Test::Int::Element::MatrixBoolVarBoolVarXY, Test::Int::Element::MatrixIntBoolVarXX, Test::Int::Element::MatrixIntBoolVarXY, Test::Int::Element::MatrixIntIntVarXX, Test::Int::Element::MatrixIntIntVarXY, Test::Int::Element::MatrixIntVarIntVarXX, Test::Int::Element::MatrixIntVarIntVarXY, Test::Int::Element::VarBoolInt, Test::Int::Element::VarBoolVar, Test::Int::Element::VarIntInt, Test::Int::Element::VarIntShared, Test::Int::Element::VarIntVar, Test::Int::Exec::BoolWait, Test::Int::Exec::IntWait, Test::Int::Exec::When, Test::Int::Extensional::OpenRegularClosed, Test::Int::Extensional::OpenRegularEmpty, Test::Int::Extensional::RegAcyclicReconvergence, Test::Int::Extensional::RegBoolCyclicFrontier, Test::Int::Extensional::RegCyclicFrontier, Test::Int::Extensional::RegDistinct, Test::Int::Extensional::RegDuplicateFinals, Test::Int::Extensional::RegEmptyDFA, Test::Int::Extensional::RegEmptyREG, Test::Int::Extensional::RegNFAPrefix, Test::Int::Extensional::RegNoAcceptingPath, Test::Int::Extensional::RegOpt, Test::Int::Extensional::RegPositionDomainPruning, Test::Int::Extensional::RegRandomDifferential, Test::Int::Extensional::RegRandomNFADifferential, Test::Int::Extensional::RegRoland, Test::Int::Extensional::RegSharedA, Test::Int::Extensional::RegSharedB, Test::Int::Extensional::RegSharedC, Test::Int::Extensional::RegSharedD, Test::Int::Extensional::RegSimpleA, Test::Int::Extensional::RegSimpleB, Test::Int::Extensional::RegSimpleC, Test::Int::Extensional::RegSparseStateNumbering, Test::Int::Extensional::RegTerminalMerged, Test::Int::Extensional::RegTerminalUnmerged, Test::Int::Extensional::SparseTupleSet, Test::Int::Extensional::SparseTupleSetIncremental, Test::Int::Extensional::SparseTupleSetNullary, Test::Int::Extensional::TupleSetBase, Test::Int::Extensional::TupleSetBool, Test::Int::Extensional::TupleSetLarge, Test::Int::Extensional::TupleSetTest, Test::Int::GCC::IntAllMax, Test::Int::GCC::IntAllMinMax, Test::Int::GCC::IntAllMinMaxDef, Test::Int::GCC::IntSome< hole >, Test::Int::GCC::VarAll, Test::Int::GCC::VarSome, Test::Int::InterDistance::Distance, Test::Int::InterDistance::Examples, Test::Int::InterDistance::Random, Test::Int::InterDistance::Variable, Test::Int::Linear::BoolInt, Test::Int::Linear::BoolVar, Test::Int::Linear::IntInt, Test::Int::Linear::IntVar, Test::Int::Member::Bool, Test::Int::Member::Int, Test::Int::MinDistance::Minimum, Test::Int::MiniModel::BoolLex, Test::Int::MiniModel::IntLex, Test::Int::MiniModelArithmetic::Abs, Test::Int::MiniModelArithmetic::Div, Test::Int::MiniModelArithmetic::Max, Test::Int::MiniModelArithmetic::MaxNary, Test::Int::MiniModelArithmetic::Min, Test::Int::MiniModelArithmetic::MinNary, Test::Int::MiniModelArithmetic::Minus, Test::Int::MiniModelArithmetic::Mod, Test::Int::MiniModelArithmetic::Mult, Test::Int::MiniModelArithmetic::Plus, Test::Int::MiniModelArithmetic::Sqr, Test::Int::MiniModelArithmetic::Sqrt, Test::Int::MiniModelBoolean::BoolElement, Test::Int::MiniModelBoolean::BoolExprConstant, Test::Int::MiniModelBoolean::BoolExprDefaultAccumulator, Test::Int::MiniModelBoolean::BoolExprInt, Test::Int::MiniModelBoolean::BoolExprInvalid, Test::Int::MiniModelBoolean::BoolExprVar, Test::Int::MiniModelCount::IntArrayInt, Test::Int::MiniModelCount::IntArrayVar, Test::Int::MiniModelCount::IntInt, Test::Int::MiniModelCount::IntVar, Test::Int::MiniModelCount::VarInt, Test::Int::MiniModelCount::VarVar, Test::Int::MiniModelLin::LinExprBool, Test::Int::MiniModelLin::LinExprDefault, Test::Int::MiniModelLin::LinExprInt, Test::Int::MiniModelLin::LinExprMixed, Test::Int::MiniModelLin::LinRelBool, Test::Int::MiniModelLin::LinRelInt, Test::Int::MiniModelLin::LinRelMixed, Test::Int::MiniModelSet::SetExprConst, Test::Int::MiniModelSet::SetExprExpr, Test::Int::NoOverlap::Int2, Test::Int::NoOverlap::IntOpt2, Test::Int::NoOverlap::Var2, Test::Int::NoOverlap::VarOpt2, Test::Int::NoOverlap::VarOptShared2, Test::Int::NValues::BoolInt, Test::Int::NValues::BoolVar, Test::Int::NValues::IntInt, Test::Int::NValues::IntVar, Test::Int::OpenList::EmptyMinimum, Test::Int::OpenTest, Test::Int::Order::Int, Test::Int::Precede::Multi, Test::Int::Precede::Single, Test::Int::Rel::BoolArrayInt, Test::Int::Rel::BoolArrayVar, Test::Int::Rel::BoolInt, Test::Int::Rel::BoolSeq, Test::Int::Rel::BoolSharedSeq, Test::Int::Rel::BoolVarXX, Test::Int::Rel::BoolVarXY, Test::Int::Rel::IntArrayDiff, Test::Int::Rel::IntArrayInt, Test::Int::Rel::IntArrayVar, Test::Int::Rel::IntInt, Test::Int::Rel::IntSeq, Test::Int::Rel::IntSharedSeq, Test::Int::Rel::IntVarXX, Test::Int::Rel::IntVarXY, Test::Int::Sequence::SequenceBoolTest, Test::Int::Sequence::SequenceIntTest, Test::Int::Sorted::NoVar, Test::Int::Sorted::PermVar, Test::Int::Unary::ManFixPUnary, Test::Int::Unary::ManFlexUnary, Test::Int::Unary::OptFixPUnary, Test::Int::Unary::OptFlexUnary, Test::Int::Unshare::Bool, Test::Int::Unshare::Failed, and Test::Int::Unshare::Int.

◆ post() [2/2]

void Test::Int::Test::post ( Gecode::Space & home,
Gecode::IntVarArray & x,
Gecode::Reify r )
virtual

Post reified constraint.

Reimplemented in Test::Int::Arithmetic::DividesXX, Test::Int::Arithmetic::DividesXY, Test::Int::Arithmetic::GcdXXX, Test::Int::Arithmetic::GcdXXY, Test::Int::Arithmetic::GcdXYX, Test::Int::Arithmetic::GcdXYZ, Test::Int::Arithmetic::ProductEmpty, Test::Int::Arithmetic::ProductInterleaved, Test::Int::Arithmetic::ProductModCoefficient, Test::Int::Arithmetic::ProductModEmpty, Test::Int::Arithmetic::ProductModFolded, Test::Int::Arithmetic::ProductModLimits, Test::Int::Arithmetic::ProductModSingleton, Test::Int::Arithmetic::ProductModVarEmpty, Test::Int::Arithmetic::ProductModVarFactorResultAlias, Test::Int::Arithmetic::ProductModVarModFactorAlias, Test::Int::Arithmetic::ProductModVarModResultAlias, Test::Int::Arithmetic::ProductModVarRepeated, Test::Int::Arithmetic::ProductModVarSingleton, Test::Int::Arithmetic::ProductModVarXYMR, Test::Int::Arithmetic::ProductModXXYAlias, Test::Int::Arithmetic::ProductModXYZR, Test::Int::Arithmetic::ProductSingleton, Test::Int::Arithmetic::ProductXXYAlias, Test::Int::Arithmetic::ProductXYZR, Test::Int::Basic::Basic, Test::Int::Dom::DomDom, Test::Int::Dom::DomInt, Test::Int::Dom::DomRange, Test::Int::Dom::DomRangeEmpty, Test::Int::Extensional::TupleSetBase, Test::Int::Extensional::TupleSetBool, Test::Int::Extensional::TupleSetLarge, Test::Int::Extensional::TupleSetTest, Test::Int::Linear::BoolInt, Test::Int::Linear::BoolVar, Test::Int::Linear::IntInt, Test::Int::Linear::IntVar, Test::Int::Member::Bool, Test::Int::Member::Int, Test::Int::MiniModelLin::LinRelBool, Test::Int::MiniModelLin::LinRelInt, Test::Int::MiniModelLin::LinRelMixed, Test::Int::MiniModelSet::SetExprConst, Test::Int::MiniModelSet::SetExprExpr, Test::Int::Rel::BoolInt, Test::Int::Rel::BoolVarXY, Test::Int::Rel::IntInt, Test::Int::Rel::IntVarXX, and Test::Int::Rel::IntVarXY.

Definition at line 477 of file int.cpp.

◆ run()

bool Test::Int::Test::run ( void )
virtual

Perform test.

Implements Test::Base.

Reimplemented in Test::Int::OpenTest.

Definition at line 481 of file int.cpp.

◆ str() [1/6]

std::string Test::Int::Test::str ( bool b)
inlinestatic

Map bool to string.

Definition at line 278 of file int.hpp.

◆ str() [2/6]

std::string Test::Int::Test::str ( int i)
inlinestatic

Map integer to string.

Definition at line 283 of file int.hpp.

◆ str() [3/6]

std::string Test::Int::Test::str ( const Gecode::IntArgs & i)
inlinestatic

Map integer array to string.

Definition at line 288 of file int.hpp.

◆ str() [4/6]

std::string Test::Int::Test::str ( Gecode::IntPropLevel ipl)
inlinestatic

Map integer propagation level to string.

Definition at line 231 of file int.hpp.

◆ str() [5/6]

std::string Test::Int::Test::str ( Gecode::IntRelType irl)
inlinestatic

Map integer relation to string.

Definition at line 247 of file int.hpp.

◆ str() [6/6]

std::string Test::Int::Test::str ( Gecode::BoolOpType bot)
inlinestatic

Map Boolean operation to string.

Definition at line 263 of file int.hpp.

◆ cmp()

template<class T>
bool Test::Int::Test::cmp ( T x,
Gecode::IntRelType r,
T y )
inlinestatic

Compare x and y with respect to r.

Definition at line 296 of file int.hpp.

Member Data Documentation

◆ arity

int Test::Int::Test::arity
protected

Number of variables.

Definition at line 273 of file int.hh.

◆ dom

Gecode::IntSet Test::Int::Test::dom
protected

Domain of variables.

Definition at line 275 of file int.hh.

◆ reified

bool Test::Int::Test::reified
protected

Does the constraint also exist as reified constraint.

Definition at line 277 of file int.hh.

◆ rms

int Test::Int::Test::rms
protected

Supported reification modes, encoded as a bit mask of 1 << Gecode::RM_*.

Definition at line 279 of file int.hh.

◆ ipl

Gecode::IntPropLevel Test::Int::Test::ipl
protected

Propagation level.

Definition at line 281 of file int.hh.

◆ contest

ConTestLevel Test::Int::Test::contest
protected

Whether to test for certain consistency.

Definition at line 283 of file int.hh.

◆ testsearch

bool Test::Int::Test::testsearch
protected

Whether to perform search test.

Definition at line 285 of file int.hh.

◆ testfix

bool Test::Int::Test::testfix
protected

Whether to perform fixpoint test.

Definition at line 287 of file int.hh.


The documentation for this class was generated from the following files: