set.hpp
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044 namespace Gecode { namespace Set {
00045
00046
00047
00048
00049
00050
00051 forceinline
00052 SetView::SetView(void) {}
00053 forceinline
00054 SetView::SetView(const SetVar& y)
00055 : VarImpView<SetVar>(y.varimp()) {}
00056 forceinline
00057 SetView::SetView(SetVarImp* y)
00058 : VarImpView<SetVar>(y) {}
00059
00060
00061
00062
00063
00064
00065 forceinline unsigned int
00066 SetView::glbSize(void) const {
00067 return x->glbSize();
00068 }
00069 forceinline unsigned int
00070 SetView::lubSize(void) const {
00071 return x->lubSize();
00072 }
00073 forceinline unsigned int
00074 SetView::unknownSize(void) const {
00075 return x->lubSize() - x->glbSize();
00076 }
00077 forceinline bool
00078 SetView::contains(int i) const {
00079 return x->knownIn(i);
00080 }
00081 forceinline bool
00082 SetView::notContains(int i) const {
00083 return x->knownOut(i);
00084 }
00085 forceinline unsigned int
00086 SetView::cardMin(void) const {
00087 return x->cardMin();
00088 }
00089 forceinline unsigned int
00090 SetView::cardMax(void) const {
00091 return x->cardMax();
00092 }
00093 forceinline int
00094 SetView::lubMin(void) const {
00095 return x->lubMin();
00096 }
00097 forceinline int
00098 SetView::lubMax(void) const {
00099 return x->lubMax();
00100 }
00101 forceinline int
00102 SetView::lubMinN(unsigned int n) const {
00103 return x->lubMinN(n);
00104 }
00105 forceinline int
00106 SetView::glbMin(void) const {
00107 return x->glbMin();
00108 }
00109 forceinline int
00110 SetView::glbMax(void) const {
00111 return x->glbMax();
00112 }
00113
00114
00115
00116
00117
00118
00119 forceinline ModEvent
00120 SetView::cardMin(Space& home, unsigned int m) {
00121 return x->cardMin(home, m);
00122 }
00123
00124 forceinline ModEvent
00125 SetView::cardMax(Space& home, unsigned int m) {
00126 return x->cardMax(home, m);
00127 }
00128
00129 forceinline ModEvent
00130 SetView::include (Space& home, int from, int to) {
00131 return x->include(home,from,to);
00132 }
00133
00134 forceinline ModEvent
00135 SetView::include (Space& home, int n) {
00136 return x->include(home,n);
00137 }
00138
00139 forceinline ModEvent
00140 SetView::exclude (Space& home, int n) {
00141 return x->exclude(home, n);
00142 }
00143
00144 forceinline ModEvent
00145 SetView::intersect (Space& home, int from, int to) {
00146 return x->intersect(home,from,to);
00147 }
00148
00149 forceinline ModEvent
00150 SetView::intersect (Space& home, int n) {
00151 return x->intersect(home,n);
00152 }
00153
00154 template<class I> ModEvent
00155 SetView::includeI (Space& home, I& iter) {
00156 return x->includeI(home, iter);
00157 }
00158
00159 forceinline ModEvent
00160 SetView::exclude (Space& home, int from, int to) {
00161 return x->exclude(home,from,to);
00162 }
00163 template<class I> ModEvent
00164 SetView::excludeI(Space& home, I& iter) {
00165 return x->excludeI(home, iter);
00166 }
00167 template<class I> ModEvent
00168 SetView::intersectI(Space& home, I& iter) {
00169 return x->intersectI(home, iter);
00170 }
00171
00172
00173
00174
00175
00176
00177
00178 forceinline ModEvent
00179 SetView::modevent(const Delta& d) { return SetVarImp::modevent(d); }
00180
00181 forceinline int
00182 SetView::glbMin(const Delta& d) const { return SetVarImp::glbMin(d); }
00183
00184 forceinline int
00185 SetView::glbMax(const Delta& d) const { return SetVarImp::glbMax(d); }
00186
00187 forceinline bool
00188 SetView::glbAny(const Delta& d) const { return SetVarImp::glbAny(d); }
00189
00190 forceinline int
00191 SetView::lubMin(const Delta& d) const { return SetVarImp::lubMin(d); }
00192
00193 forceinline int
00194 SetView::lubMax(const Delta& d) const { return SetVarImp::lubMax(d); }
00195
00196 forceinline bool
00197 SetView::lubAny(const Delta& d) const { return SetVarImp::lubAny(d); }
00198
00199
00204 template<>
00205 class LubRanges<SetView> : public LubRanges<SetVarImp*> {
00206 public:
00208
00209
00210 LubRanges(void);
00212 LubRanges(const SetView& x);
00214 void init(const SetView& x);
00216 };
00217
00218 forceinline
00219 LubRanges<SetView>::LubRanges(void) {}
00220
00221 forceinline
00222 LubRanges<SetView>::LubRanges(const SetView& x)
00223 : LubRanges<SetVarImp*>(x.varimp()) {}
00224
00225 forceinline void
00226 LubRanges<SetView>::init(const SetView& x) {
00227 LubRanges<SetVarImp*>::init(x.varimp());
00228 }
00229
00230
00235 template<>
00236 class GlbRanges<SetView> : public GlbRanges<SetVarImp*> {
00237 public:
00239
00240
00241 GlbRanges(void);
00243 GlbRanges(const SetView& x);
00245 void init(const SetView& x);
00246 };
00247
00248 forceinline
00249 GlbRanges<SetView>::GlbRanges(void) {}
00250
00251 forceinline
00252 GlbRanges<SetView>::GlbRanges(const SetView& x)
00253 : GlbRanges<SetVarImp*>(x.varimp()) {}
00254
00255 forceinline void
00256 GlbRanges<SetView>::init(const SetView& x) {
00257 GlbRanges<SetVarImp*>::init(x.varimp());
00258 }
00259
00260 }}
00261
00262
00263