float.hpp /usr/include/gecode/float/view.hpp Gecode Gecode::Float /*-*-mode:C++;c-basic-offset:2;indent-tabs-mode:nil-*-*/ /* *Mainauthors: *ChristianSchulte<schulte@gecode.org> *VincentBarichard<Vincent.Barichard@univ-angers.fr> * *Copyright: *ChristianSchulte,2002 *VincentBarichard,2012 * *Lastmodified: *$Date:2012-04-0613:04:47+0200(Fri,06Apr2012)$by$Author:schulte$ *$Revision:12711$ * *ThisfileispartofGecode,thegenericconstraint *developmentenvironment: *http://www.gecode.org * *Permissionisherebygranted,freeofcharge,toanypersonobtaining *acopyofthissoftwareandassociateddocumentationfiles(the *"Software"),todealintheSoftwarewithoutrestriction,including *withoutlimitationtherightstouse,copy,modify,merge,publish, *distribute,sublicense,and/orsellcopiesoftheSoftware,andto *permitpersonstowhomtheSoftwareisfurnishedtodoso,subjectto *thefollowingconditions: * *Theabovecopyrightnoticeandthispermissionnoticeshallbe *includedinallcopiesorsubstantialportionsoftheSoftware. * *THESOFTWAREISPROVIDED"ASIS",WITHOUTWARRANTYOFANYKIND, *EXPRESSORIMPLIED,INCLUDINGBUTNOTLIMITEDTOTHEWARRANTIESOF *MERCHANTABILITY,FITNESSFORAPARTICULARPURPOSEAND *NONINFRINGEMENT.INNOEVENTSHALLTHEAUTHORSORCOPYRIGHTHOLDERSBE *LIABLEFORANYCLAIM,DAMAGESOROTHERLIABILITY,WHETHERINANACTION *OFCONTRACT,TORTOROTHERWISE,ARISINGFROM,OUTOFORINCONNECTION *WITHTHESOFTWAREORTHEUSEOROTHERDEALINGSINTHESOFTWARE. * */ namespaceGecode{namespaceFloat{ /* *Constructorsandinitialization * */ forceinline FloatView::FloatView(void){} forceinline FloatView::FloatView(constFloatVar&y) :VarImpView<FloatVar>(y.varimp()){} forceinline FloatView::FloatView(FloatVarImp*y) :VarImpView<FloatVar>(y){} /* *Valueaccess * */ forceinlineFloatVal FloatView::domain(void)const{ returnx->domain(); } forceinlineFloatNum FloatView::min(void)const{ returnx->min(); } forceinlineFloatNum FloatView::max(void)const{ returnx->max(); } forceinlineFloatNum FloatView::med(void)const{ returnx->med(); } forceinlineFloatVal FloatView::val(void)const{ returnx->val(); } forceinlineFloatNum FloatView::size(void)const{ returnx->size(); } /* *Domaintests * */ forceinlinebool FloatView::zero_in(void)const{ returnx->zero_in(); } forceinlinebool FloatView::in(FloatNumn)const{ returnx->in(n); } forceinlinebool FloatView::in(constFloatVal&n)const{ returnx->in(n); } /* *Domainupdatebyvalue * */ forceinlineModEvent FloatView::lq(Space&home,intn){ returnx->lq(home,n); } forceinlineModEvent FloatView::lq(Space&home,FloatNumn){ returnx->lq(home,n); } forceinlineModEvent FloatView::lq(Space&home,FloatValn){ returnx->lq(home,n); } forceinlineModEvent FloatView::gq(Space&home,intn){ returnx->gq(home,n); } forceinlineModEvent FloatView::gq(Space&home,FloatNumn){ returnx->gq(home,n); } forceinlineModEvent FloatView::gq(Space&home,FloatValn){ returnx->gq(home,n); } forceinlineModEvent FloatView::eq(Space&home,intn){ returnx->eq(home,n); } forceinlineModEvent FloatView::eq(Space&home,FloatNumn){ returnx->eq(home,n); } forceinlineModEvent FloatView::eq(Space&home,constFloatVal&n){ returnx->eq(home,n); } /* *Deltainformationforadvisors * */ forceinlineFloatNum FloatView::min(constDelta&d)const{ returnFloatVarImp::min(d); } forceinlineFloatNum FloatView::max(constDelta&d)const{ returnFloatVarImp::max(d); } forceinlineModEventDelta FloatView::med(ModEventme){ returnVarImpView<FloatVar>::med(me); } }} //STATISTICS:float-var