Generated on Thu Jul 25 2019 00:00:00 for Gecode by doxygen 1.8.15

Choose view according to merit. More...

#include <brancher-view-sel.hpp>

Protected Types

typedef ViewSel< typename Merit::View >::Var Var
 
typedef ViewSel< typename Merit::View >::View View
 
typedef Merit::Val Val
 Type of merit. More...
 

Protected Attributes

Choose c
 How to choose. More...
 
Merit m
 The merit object used. More...
 

Initialization

 ViewSelChoose (Space &home, const VarBranch< Var > &vb)
 Constructor for creation. More...
 
 ViewSelChoose (Space &home, bool shared, ViewSelChoose< Choose, Merit > &vs)
 Constructor for copying during cloning. More...
 

View selection and tie breaking

virtual int select (Space &home, ViewArray< View > &x, int s)
 Select a view from x starting from s and return its position. More...
 
virtual int select (Space &home, ViewArray< View > &x, int s, BrancherFilter< View > &f)
 Select a view from x starting from s and return its position. More...
 
virtual void ties (Space &home, ViewArray< View > &x, int s, int *ties, int &n)
 Select ties from x starting from s. More...
 
virtual void ties (Space &home, ViewArray< View > &x, int s, int *ties, int &n, BrancherFilter< View > &f)
 Select ties from x starting from s. More...
 
virtual void brk (Space &home, ViewArray< View > &x, int *ties, int &n)
 Break ties in x and update to new ties. More...
 
virtual int select (Space &home, ViewArray< View > &x, int *ties, int n)
 Select a view from x considering views with positions in ties. More...
 

Resource management and cloning

virtual bool notice (void) const
 Whether dispose must always be called (that is, notice is needed) More...
 
virtual void dispose (Space &home)
 Delete view selection. More...
 

Additional Inherited Members

- Public Types inherited from Gecode::ViewSel< Merit::View >
typedef Merit::View View
 Define the view type. More...
 
typedef View::VarType Var
 The corresponding variable type. More...
 
- Public Member Functions inherited from Gecode::ViewSel< Merit::View >
 ViewSel (Space &home, const VarBranch< Var > &vb)
 Constructor for creation. More...
 
 ViewSel (Space &home, bool shared, ViewSel< View > &vs)
 Constructor for copying during cloning. More...
 
virtual int select (Space &home, ViewArray< View > &x, int s)=0
 Select a view from x starting from s and return its position. More...
 
virtual int select (Space &home, ViewArray< View > &x, int s, BrancherFilter< View > &f)=0
 Select a view from x starting from s and return its position. More...
 
virtual int select (Space &home, ViewArray< View > &x, int s, BrancherNoFilter< View > &f)
 Select a view from x starting from s and return its position. More...
 
virtual int select (Space &home, ViewArray< View > &x, int *ties, int n)=0
 Select a view from x considering views with positions in ties. More...
 
virtual void ties (Space &home, ViewArray< View > &x, int s, int *ties, int &n)=0
 Select ties from x starting from s. More...
 
virtual void ties (Space &home, ViewArray< View > &x, int s, int *ties, int &n, BrancherFilter< View > &f)=0
 Select ties from x starting from s. More...
 
virtual void ties (Space &home, ViewArray< View > &x, int s, int *ties, int &n, BrancherNoFilter< View > &f)
 Select ties from x starting from s. More...
 
virtual void brk (Space &home, ViewArray< View > &x, int *ties, int &n)=0
 Break ties in x and update to new ties. More...
 
virtual ViewSel< View > * copy (Space &home, bool shared)=0
 Create copy during cloning. More...
 
virtual ~ViewSel (void)
 Unused destructor. More...
 
- Static Public Member Functions inherited from Gecode::ViewSel< Merit::View >
static void * operator new (size_t s, Space &home)
 Allocate memory from space. More...
 
static void operator delete (void *p, Space &home)
 Return memory to space. More...
 
static void operator delete (void *p)
 Needed for exceptions. More...
 

Detailed Description

template<class Choose, class Merit>
class Gecode::ViewSelChoose< Choose, Merit >

Choose view according to merit.

Definition at line 210 of file brancher-view-sel.hpp.

Member Typedef Documentation

◆ Var

template<class Choose, class Merit>
typedef ViewSel<typename Merit::View>::Var Gecode::ViewSelChoose< Choose, Merit >::Var
protected

Definition at line 212 of file brancher-view-sel.hpp.

◆ View

template<class Choose, class Merit>
typedef ViewSel<typename Merit::View>::View Gecode::ViewSelChoose< Choose, Merit >::View
protected

Definition at line 213 of file brancher-view-sel.hpp.

◆ Val

template<class Choose, class Merit>
typedef Merit::Val Gecode::ViewSelChoose< Choose, Merit >::Val
protected

Type of merit.

Definition at line 215 of file brancher-view-sel.hpp.

Constructor & Destructor Documentation

◆ ViewSelChoose() [1/2]

template<class Choose , class Merit >
Gecode::ViewSelChoose< Choose, Merit >::ViewSelChoose ( Space home,
const VarBranch< Var > &  vb 
)
inline

Constructor for creation.

Definition at line 564 of file brancher-view-sel.hpp.

◆ ViewSelChoose() [2/2]

template<class Choose, class Merit>
Gecode::ViewSelChoose< Choose, Merit >::ViewSelChoose ( Space home,
bool  shared,
ViewSelChoose< Choose, Merit > &  vs 
)
inline

Constructor for copying during cloning.

Definition at line 569 of file brancher-view-sel.hpp.

Member Function Documentation

◆ select() [1/3]

template<class Choose , class Merit >
int Gecode::ViewSelChoose< Choose, Merit >::select ( Space home,
ViewArray< View > &  x,
int  s 
)
virtual

Select a view from x starting from s and return its position.

Definition at line 575 of file brancher-view-sel.hpp.

◆ select() [2/3]

template<class Choose , class Merit >
int Gecode::ViewSelChoose< Choose, Merit >::select ( Space home,
ViewArray< View > &  x,
int  s,
BrancherFilter< View > &  f 
)
virtual

Select a view from x starting from s and return its position.

Definition at line 592 of file brancher-view-sel.hpp.

◆ ties() [1/2]

template<class Choose , class Merit >
void Gecode::ViewSelChoose< Choose, Merit >::ties ( Space home,
ViewArray< View > &  x,
int  s,
int *  ties,
int &  n 
)
virtual

◆ ties() [2/2]

template<class Choose , class Merit >
void Gecode::ViewSelChoose< Choose, Merit >::ties ( Space home,
ViewArray< View > &  x,
int  s,
int *  ties,
int &  n,
BrancherFilter< View > &  f 
)
virtual

◆ brk()

template<class Choose , class Merit >
void Gecode::ViewSelChoose< Choose, Merit >::brk ( Space home,
ViewArray< View > &  x,
int *  ties,
int &  n 
)
virtual

◆ select() [3/3]

template<class Choose , class Merit >
int Gecode::ViewSelChoose< Choose, Merit >::select ( Space home,
ViewArray< View > &  x,
int *  ties,
int  n 
)
virtual

Select a view from x considering views with positions in ties.

Definition at line 680 of file brancher-view-sel.hpp.

◆ notice()

template<class Choose , class Merit >
bool Gecode::ViewSelChoose< Choose, Merit >::notice ( void  ) const
virtual

Whether dispose must always be called (that is, notice is needed)

Reimplemented from Gecode::ViewSel< Merit::View >.

Reimplemented in Gecode::ViewSelChooseTbl< Choose, Merit >, Gecode::ViewSelChooseTbl< ChooseMin, Merit >, and Gecode::ViewSelChooseTbl< ChooseMax, Merit >.

Definition at line 695 of file brancher-view-sel.hpp.

◆ dispose()

template<class Choose , class Merit >
void Gecode::ViewSelChoose< Choose, Merit >::dispose ( Space home)
virtual

Member Data Documentation

◆ c

template<class Choose, class Merit>
Choose Gecode::ViewSelChoose< Choose, Merit >::c
protected

How to choose.

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

◆ m

template<class Choose, class Merit>
Merit Gecode::ViewSelChoose< Choose, Merit >::m
protected

The merit object used.

Definition at line 219 of file brancher-view-sel.hpp.


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