51 (
"problem",
"material excess");
53 (
"problem",
"material shortage");
63 (
"problem",
"invalid data");
65 (
"problem",
"unplanned");
67 (
"problem",
"precedence");
69 (
"problem",
"before fence");
71 (
"problem",
"before current");
73 (
"problem",
"underload");
75 (
"problem",
"overload");
80 x.
setDoc(
"frePPLe problem");
83 x.
addMethod(
"toXML",
toXML, METH_VARARGS,
"return a XML representation");
105 if ((
owner->firstProblem && *
this < *(
owner->firstProblem))
106 || !
owner->firstProblem)
110 owner->firstProblem =
this;
117 while (curProblem && !(*
this < *curProblem))
119 prevProblem = curProblem;
134 if (
owner->firstProblem ==
this)
159 if (useProblemDetection && !b)
162 else if (!useProblemDetection && b)
167 useProblemDetection=b;
174 if (!anyChange && !computationBusy)
return;
176 computationBusy =
true;
178 static Mutex computationbusy;
206 computationBusy =
false;
238 i->getEntity()->setChanged(
true);
246 if (!p.firstProblem)
return;
249 for (
Problem *cur=p.firstProblem; cur; )
256 p.firstProblem = NULL;
269 for (; piter!=
end(); ++piter)
373 case 0:
delete bufIter;
return;
375 case 1:
delete resIter;
return;
377 case 2:
delete operIter;
return;
379 case 3:
delete demIter;
return;
390 if (type==0) bufIter =
new Buffer::iterator(*(o.
bufIter));
391 else if (type==1) resIter =
new Resource::iterator(*(o.
resIter));
393 else if (type==3) demIter =
new Demand::iterator(*(o.
demIter));
401 if (
this == &o)
return *
this;
406 if (type==0) bufIter =
new Buffer::iterator(*(o.
bufIter));
407 else if (type==1) resIter =
new Resource::iterator(*(o.
resIter));
409 else if (type==3) demIter =
new Demand::iterator(*(o.
demIter));
418 if (type != t.type)
return true;
424 case 0:
return *bufIter != *(t.
bufIter);
426 case 1:
return *resIter != *(t.
resIter);
428 case 2:
return *operIter != *(t.
operIter);
430 case 3:
return *demIter != *(t.
demIter);
433 default:
return false;
443 case 0:
return **bufIter;
445 case 1:
return **resIter;
447 case 2:
return **operIter;
449 case 3:
return **demIter;
460 case 0:
return &**bufIter;
462 case 1:
return &**resIter;
464 case 2:
return &**operIter;
466 case 3:
return &**demIter;
489 if (!iter)
return *
this;
515 if (!i)
return begin();
555 if (x->nextProblem == c)
557 x->nextProblem = NULL;
563 for (
Problem *cur = c ? c : first; cur; )
572 if (!c) first = NULL;
594 p =
new ProblemBeforeCurrent(const_cast<Operation*>(dynamic_cast<const Operation*>(o)), st, nd, w);
596 p =
new ProblemBeforeFence(const_cast<Operation*>(dynamic_cast<const Operation*>(o)), st, nd, w);
598 throw LogicException(
"Problem factory can't create this type of problem");
639 if (!p->nextProblem)
return p;