Generated on Mon May 5 05:54:12 2008 for Gecode by doxygen 1.5.5

Gecode::ViewTuple< View, n > Class Template Reference
[Programming views for variables]

List of all members.


Detailed Description

template<class View, unsigned int n>
class Gecode::ViewTuple< View, n >

Tuple of views.

Note that when tuples of views are stored inside ViewArrays, then operations that check for sharing or equality on these arrays do not work like expected.

Definition at line 225 of file view.icc.


Initialization

 ViewTuple (void)
 Default constructor.
 ViewTuple (Space *home, const Reflection::VarMap &vars, Reflection::Arg *arg)
 Construct from specification.

Component access

View & operator[] (unsigned int i)
 Return i-th component of tuple.
const View & operator[] (unsigned int i) const
 Return i-th component of tuple.

Dependencies

void subscribe (Space *home, Propagator *p, PropCond pc, bool process=true)
 Subscribe propagator p with propagation condition pc to variable.
void cancel (Space *home, Propagator *p, PropCond pc)
 Cancel subscription of propagator p with propagation condition pc to view.
void subscribe (Space *home, Advisor *a)
 Subscribe advisor a to variable.
void cancel (Space *home, Advisor *a)
 Cancel subscription of advisor a.

Cloning

void update (Space *home, bool share, ViewTuple &xs)
 Update this view to be a clone of view tuple xs.

Reflection

Reflection::Argspec (const Space *home, Reflection::VarMap &m) const
 Return specification for this view, using variable map m.
static Support::Symbol type (void)

View comparison

template<class View, unsigned int n>
bool same (const ViewTuple< View, n > &x, const ViewTuple< View, n > &y)
 Test whether tuples x and y are the same.
template<class View, unsigned int n>
bool before (const ViewTuple< View, n > &x, const ViewTuple< View, n > &y)
 Test whether tuple x is before y (arbitrary order).

Constructor & Destructor Documentation

template<class View, unsigned int n>
Gecode::ViewTuple< View, n >::ViewTuple ( void   )  [inline]

Default constructor.

Definition at line 509 of file view.icc.

template<class View, unsigned int n>
Gecode::ViewTuple< View, n >::ViewTuple ( Space home,
const Reflection::VarMap vars,
Reflection::Arg arg 
) [inline]

Construct from specification.

Definition at line 513 of file view.icc.


Member Function Documentation

template<class View, unsigned int n>
View & Gecode::ViewTuple< View, n >::operator[] ( unsigned int  i  )  [inline]

Return i-th component of tuple.

Definition at line 528 of file view.icc.

template<class View, unsigned int n>
const View & Gecode::ViewTuple< View, n >::operator[] ( unsigned int  i  )  const [inline]

Return i-th component of tuple.

Definition at line 522 of file view.icc.

template<class View, unsigned int n>
void Gecode::ViewTuple< View, n >::subscribe ( Space home,
Propagator p,
PropCond  pc,
bool  process = true 
) [inline]

Subscribe propagator p with propagation condition pc to variable.

In case process is false, the propagator is just subscribed but not processed for execution (this must be used when creating subscriptions during propagation).

Definition at line 535 of file view.icc.

template<class View, unsigned int n>
void Gecode::ViewTuple< View, n >::cancel ( Space home,
Propagator p,
PropCond  pc 
) [inline]

Cancel subscription of propagator p with propagation condition pc to view.

Definition at line 542 of file view.icc.

template<class View, unsigned int n>
void Gecode::ViewTuple< View, n >::subscribe ( Space home,
Advisor a 
) [inline]

Subscribe advisor a to variable.

Definition at line 548 of file view.icc.

template<class View, unsigned int n>
void Gecode::ViewTuple< View, n >::cancel ( Space home,
Advisor a 
) [inline]

Cancel subscription of advisor a.

Definition at line 554 of file view.icc.

template<class View, unsigned int n>
void Gecode::ViewTuple< View, n >::update ( Space home,
bool  share,
ViewTuple< View, n > &  xs 
) [inline]

Update this view to be a clone of view tuple xs.

Definition at line 560 of file view.icc.

template<class View, unsigned int n>
Reflection::Arg * Gecode::ViewTuple< View, n >::spec ( const Space home,
Reflection::VarMap m 
) const [inline]

Return specification for this view, using variable map m.

Definition at line 566 of file view.icc.

template<class View, unsigned int n>
Support::Symbol Gecode::ViewTuple< View, n >::type ( void   )  [inline, static]

TODO! FIXME!

Definition at line 574 of file view.icc.


Friends And Related Function Documentation

template<class View, unsigned int n>
bool same ( const ViewTuple< View, n > &  x,
const ViewTuple< View, n > &  y 
) [related]

Test whether tuples x and y are the same.

Definition at line 581 of file view.icc.

template<class View, unsigned int n>
bool before ( const ViewTuple< View, n > &  x,
const ViewTuple< View, n > &  y 
) [related]

Test whether tuple x is before y (arbitrary order).

Definition at line 589 of file view.icc.


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