Generated on for Gecode by doxygen 1.17.0
Gecode::Search::Par::Slave< Collect > Class Template Reference

Runnable slave of a portfolio master. More...

#include <gecode/search/par/pbs.hh>

Classes

class  Completion
 Completion event for the current run. More...

Public Member Functions

 Slave (PBS< Collect > *m, Engine *s, Stop *so)
 Initialize with master m, slave s, and its stop object so.
Statistics statistics (void) const
 Return statistics of slave.
bool stopped (void) const
 Check whether slave has been stopped.
virtual Support::Terminatorterminator (void) const
 Return the completion terminator.
void wait (void)
 Wait for the slave to complete its current run.
void constrain (const Space &b)
 Constrain with better solution b.
virtual void run (void)
 Perform one run.
virtual ~Slave (void)
 Delete slave.
Public Member Functions inherited from Gecode::Support::Runnable
 Runnable (bool d=true)
 Initialize, d defines whether object is deleted when terminated.
void todelete (bool d)
 Set whether to delete upon termination.
bool todelete (void) const
 Return whether to be deleted upon termination.
virtual ~Runnable (void)
 Destructor.

Protected Attributes

Gecode::Search::Par::Slave::Completion completion
PBS< Collect > * master
 The master engine.
Engineslave
 The slave engine.
Stopstop
 Stop object.

Additional Inherited Members

Static Public Member Functions inherited from Gecode::Support::Runnable
static void * operator new (size_t s)
 Allocate memory from heap.
static void operator delete (void *p)
 Free memory allocated from heap.

Detailed Description

template<class Collect>
class Gecode::Search::Par::Slave< Collect >

Runnable slave of a portfolio master.

Definition at line 72 of file pbs.hh.

Constructor & Destructor Documentation

◆ Slave()

template<class Collect>
Gecode::Search::Par::Slave< Collect >::Slave ( PBS< Collect > * m,
Engine * s,
Stop * so )
inline

Initialize with master m, slave s, and its stop object so.

Definition at line 153 of file pbs.hpp.

◆ ~Slave()

template<class Collect>
Gecode::Search::Par::Slave< Collect >::~Slave ( void )
virtual

Delete slave.

Definition at line 181 of file pbs.hpp.

Member Function Documentation

◆ statistics()

template<class Collect>
Statistics Gecode::Search::Par::Slave< Collect >::statistics ( void ) const
inline

Return statistics of slave.

Definition at line 157 of file pbs.hpp.

◆ stopped()

template<class Collect>
bool Gecode::Search::Par::Slave< Collect >::stopped ( void ) const
inline

Check whether slave has been stopped.

Definition at line 162 of file pbs.hpp.

◆ terminator()

template<class Collect>
Support::Terminator * Gecode::Search::Par::Slave< Collect >::terminator ( void ) const
inlinevirtual

Return the completion terminator.

Reimplemented from Gecode::Support::Runnable.

Definition at line 167 of file pbs.hpp.

◆ wait()

template<class Collect>
void Gecode::Search::Par::Slave< Collect >::wait ( void )
inline

Wait for the slave to complete its current run.

Definition at line 172 of file pbs.hpp.

◆ constrain()

template<class Collect>
void Gecode::Search::Par::Slave< Collect >::constrain ( const Space & b)
inline

Constrain with better solution b.

Definition at line 177 of file pbs.hpp.

◆ run()

template<class Collect>
void Gecode::Search::Par::Slave< Collect >::run ( void )
virtual

Perform one run.

Implements Gecode::Support::Runnable.

Definition at line 236 of file pbs.hpp.

Member Data Documentation

◆ completion

template<class Collect>
Gecode::Search::Par::Slave::Completion Gecode::Search::Par::Slave< Collect >::completion
protected

◆ master

template<class Collect>
PBS<Collect>* Gecode::Search::Par::Slave< Collect >::master
protected

The master engine.

Definition at line 88 of file pbs.hh.

◆ slave

template<class Collect>
Engine* Gecode::Search::Par::Slave< Collect >::slave
protected

The slave engine.

Definition at line 90 of file pbs.hh.

◆ stop

template<class Collect>
Stop* Gecode::Search::Par::Slave< Collect >::stop
protected

Stop object.

Definition at line 92 of file pbs.hh.


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