Generated on Wed Nov 1 15:04:44 2006 for Gecode by doxygen 1.4.5

minmax.icc

Go to the documentation of this file.
00001 /*
00002  *  Main authors:
00003  *     Guido Tack <tack@gecode.org>
00004  *     Christian Schulte <schulte@gecode.org>
00005  *     Gabor Szokoli <szokoli@gecode.org>
00006  *
00007  *  Copyright:
00008  *     Guido Tack, 2004
00009  *     Christian Schulte, 2004
00010  *     Gabor Szokoli, 2004
00011  *
00012  *  Last modified:
00013  *     $Date: 2006-04-11 15:58:37 +0200 (Tue, 11 Apr 2006) $ by $Author: tack $
00014  *     $Revision: 3188 $
00015  *
00016  *  This file is part of Gecode, the generic constraint
00017  *  development environment:
00018  *     http://www.gecode.org
00019  *
00020  *  See the file "LICENSE" for information on usage and
00021  *  redistribution of this file, and for a
00022  *     DISCLAIMER OF ALL WARRANTIES.
00023  *
00024  */
00025 
00026 
00027 
00028 #include "gecode/set.hh"
00029 #include "gecode/int.hh"
00030 
00031 namespace Gecode { namespace Set { namespace Int {
00032 
00033   forceinline
00034   MinElement::MinElement(Space* home, SetView y0, Gecode::Int::IntView y1)
00035     : IntSetPropagator<SetView,PC_SET_ANY,
00036                        Gecode::Int::PC_INT_BND> (home, y0, y1) {}
00037 
00038   forceinline ExecStatus
00039   MinElement::post(Space* home, SetView x0,
00040                    Gecode::Int::IntView x1) {
00041     GECODE_ME_CHECK(x0.cardMin(home,1));
00042     (void) new (home) MinElement(home,x0,x1);
00043     return ES_OK;
00044   }
00045 
00046   forceinline
00047   MinElement::MinElement(Space* home, bool share, MinElement& p)
00048     : IntSetPropagator<SetView,PC_SET_ANY,
00049                        Gecode::Int::PC_INT_BND> (home, share, p) {}
00050 
00051   forceinline
00052   MaxElement::MaxElement(Space* home, SetView y0, Gecode::Int::IntView y1)
00053     : IntSetPropagator<SetView,PC_SET_ANY,
00054                        Gecode::Int::PC_INT_BND> (home, y0, y1) {}
00055 
00056   forceinline
00057   MaxElement::MaxElement(Space* home, bool share, MaxElement& p)
00058     : IntSetPropagator<SetView,PC_SET_ANY,
00059                        Gecode::Int::PC_INT_BND> (home, share, p) {}
00060 
00061 }}}
00062 
00063 // STATISTICS: set-prop