Generated on Wed Nov 5 2014 05:18:35 for Gecode by doxygen 1.7.6.1
Setting up scripts

Functions

 Gecode::Space::Space (void)
 Default constructor.
virtual Gecode::Space::~Space (void)
 Destructor.
 Gecode::Space::Space (bool share, Space &s)
 Constructor for cloning.
virtual Space * Gecode::Space::copy (bool share)=0
 Copying member function.
virtual void Gecode::Space::constrain (const Space &best)
 Constrain function for best solution search.
virtual void Gecode::Space::master (unsigned long int i, const Space *s, NoGoods &ng)
 Master configuration function for restart meta search engine.
virtual void Gecode::Space::slave (unsigned long int i, const Space *s)
 Slave configuration function for restart meta search engine.
static void * Gecode::Space::operator new (size_t)
 Allocate memory from heap for new space.
static void Gecode::Space::operator delete (void *)
 Free memory allocated from heap.

Detailed Description

Scripts (or models) are programmed by inheriting from the class Gecode::Space. For many examples see Example scripts (models).


Function Documentation

Default constructor.

Definition at line 113 of file core.cpp.

Gecode::Space::~Space ( void  ) [virtual]

Destructor.

Definition at line 216 of file core.cpp.

Gecode::Space::Space ( bool  share,
Space s 
)

Constructor for cloning.

Must copy and update all data structures (such as variables and variable arrays) required by the subclass of Space.

If share is true, share all data structures among copies. Otherwise, make independent copies.

Definition at line 499 of file core.cpp.

void Gecode::Space::constrain ( const Space best) [virtual]

Constrain function for best solution search.

Must constrain this space to be better than the so far best solution best.

The default function does nothing.

Reimplemented in Gecode::MiniModel::FloatOptimizeSpace< frt >, Gecode::MiniModel::IntOptimizeSpace< irt >, Gecode::FlatZinc::FlatZincSpace, Test::Search::HasSolutions, Test::Search::SolveImmediate, and Test::Search::FailImmediate.

Definition at line 644 of file core.cpp.

void Gecode::Space::master ( unsigned long int  i,
const Space s,
NoGoods ng 
) [virtual]

Master configuration function for restart meta search engine.

A restart meta search engine calls this function on its master space whenever it finds a solution or exploration restarts. i is the number of the restart. s is either the solution space or NULL. ng are nogoods recorded from the last restart (only if s is not a solution).

The default function does nothing.

Reimplemented in Test::Search::HasSolutions.

Definition at line 648 of file core.cpp.

void Gecode::Space::slave ( unsigned long int  i,
const Space s 
) [virtual]

Slave configuration function for restart meta search engine.

A restart meta search engine calls this function on its slave space whenever it finds a solution or exploration restarts. i is the number of the restart. s is either the solution space or NULL.

The default function does nothing.

Definition at line 653 of file core.cpp.

void * Gecode::Space::operator new ( size_t  s) [inline, static]

Allocate memory from heap for new space.

Definition at line 2296 of file core.hpp.

void Gecode::Space::operator delete ( void *  p) [inline, static]

Free memory allocated from heap.

Definition at line 2300 of file core.hpp.