Generated on Thu Jan 31 2019 20:56:47 for Gecode by doxygen 1.8.15
Gecode::ViewBrancher< View, Filter, n > Class Template Reference

Generic brancher by view selection. More...

#include <brancher-view.hpp>

Public Member Functions

virtual bool status (const Space &home) const
 Check status of brancher, return true if alternatives left. More...
 
virtual size_t dispose (Space &home)
 Delete brancher and return its size. More...
 
- Public Member Functions inherited from Gecode::Brancher
virtual const Choicechoice (Space &home)=0
 Return choice. More...
 
virtual const Choicechoice (const Space &home, Archive &e)=0
 Return choice from e. More...
 
virtual ExecStatus commit (Space &home, const Choice &c, unsigned int a)=0
 Commit for choice c and alternative a. More...
 
virtual NGLngl (Space &home, const Choice &c, unsigned int a) const
 Create no-good literal for choice c and alternative a. More...
 
virtual void print (const Space &home, const Choice &c, unsigned int a, std::ostream &o) const
 Print branch for choice c and alternative a. More...
 
unsigned int id (void) const
 Return brancher id. More...
 
BrancherGroup group (void) const
 Return group brancher belongs to. More...
 
void group (BrancherGroup g)
 Add brancher to group g. More...
 
- Public Member Functions inherited from Gecode::Actor
virtual Actorcopy (Space &home, bool share)=0
 Create copy. More...
 
virtual ~Actor (void)
 To avoid warnings. More...
 

Protected Types

typedef View::VarType Var
 The corresponding variable. More...
 

Protected Member Functions

Pos pos (Space &home)
 Return position information. More...
 
View view (const Pos &p) const
 Return view according to position information p. More...
 
 ViewBrancher (Space &home, bool shared, ViewBrancher< View, Filter, n > &b)
 Constructor for cloning b. More...
 
 ViewBrancher (Home home, ViewArray< View > &x, ViewSel< View > *vs[n], BranchFilter< Var > bf)
 Constructor for creation. More...
 
- Protected Member Functions inherited from Gecode::Brancher
 Brancher (Home home)
 Constructor for creation. More...
 
 Brancher (Space &home, bool share, Brancher &b)
 Constructor for cloning b. More...
 

Protected Attributes

ViewArray< View > x
 Views to branch on. More...
 
int start
 Unassigned views start at x[start]. More...
 
ViewSel< View > * vs [n]
 View selection objects. More...
 
Filter f
 Filter function. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from Gecode::Actor
static void * operator new (size_t s)
 Not used. More...
 
static void operator delete (void *p)
 Not used. More...
 
static void * operator new (size_t s, Space &home)
 Allocate memory from space. More...
 
static void operator delete (void *p, Space &home)
 No-op for exceptions. More...
 

Detailed Description

template<class View, class Filter, int n>
class Gecode::ViewBrancher< View, Filter, n >

Generic brancher by view selection.

Defined for views of type View and n view selectors for tie-breaking.

Definition at line 79 of file brancher-view.hpp.

Member Typedef Documentation

◆ Var

template<class View, class Filter, int n>
typedef View::VarType Gecode::ViewBrancher< View, Filter, n >::Var
protected

The corresponding variable.

Definition at line 82 of file brancher-view.hpp.

Constructor & Destructor Documentation

◆ ViewBrancher() [1/2]

template<class View, class Filter, int n>
Gecode::ViewBrancher< View, Filter, n >::ViewBrancher ( Space home,
bool  shared,
ViewBrancher< View, Filter, n > &  b 
)
inlineprotected

Constructor for cloning b.

Definition at line 155 of file brancher-view.hpp.

◆ ViewBrancher() [2/2]

template<class View, class Filter, int n>
Gecode::ViewBrancher< View, Filter, n >::ViewBrancher ( Home  home,
ViewArray< View > &  x,
ViewSel< View > *  vs[n],
BranchFilter< Var bf 
)
inlineprotected

Constructor for creation.

Definition at line 140 of file brancher-view.hpp.

Member Function Documentation

◆ pos()

template<class View , class Filter , int n>
Pos Gecode::ViewBrancher< View, Filter, n >::pos ( Space home)
inlineprotected

Return position information.

Definition at line 177 of file brancher-view.hpp.

◆ view()

template<class View , class Filter , int n>
View Gecode::ViewBrancher< View, Filter, n >::view ( const Pos p) const
inlineprotected

Return view according to position information p.

Definition at line 217 of file brancher-view.hpp.

◆ status()

template<class View , class Filter , int n>
bool Gecode::ViewBrancher< View, Filter, n >::status ( const Space home) const
virtual

Check status of brancher, return true if alternatives left.

Implements Gecode::Brancher.

Definition at line 166 of file brancher-view.hpp.

◆ dispose()

template<class View , class Filter , int n>
size_t Gecode::ViewBrancher< View, Filter, n >::dispose ( Space home)
inlinevirtual

Member Data Documentation

◆ x

template<class View, class Filter, int n>
ViewArray<View> Gecode::ViewBrancher< View, Filter, n >::x
protected

Views to branch on.

Definition at line 84 of file brancher-view.hpp.

◆ start

template<class View, class Filter, int n>
int Gecode::ViewBrancher< View, Filter, n >::start
mutableprotected

Unassigned views start at x[start].

Definition at line 86 of file brancher-view.hpp.

◆ vs

template<class View, class Filter, int n>
ViewSel<View>* Gecode::ViewBrancher< View, Filter, n >::vs[n]
protected

View selection objects.

Definition at line 88 of file brancher-view.hpp.

◆ f

template<class View, class Filter, int n>
Filter Gecode::ViewBrancher< View, Filter, n >::f
protected

Filter function.

Definition at line 90 of file brancher-view.hpp.


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