if (!(linearFunction->getDomain()->lowerBoundaryExist())) {
vLinearFunctions.push_back(linearFunction);
#ifdef PRINT
printf(" - added function\n");
#endif // PRINT
return true;
}
}
else
{
//printf("nicht empty\n");
if (vLinearFunctions.back()->getDomain()->upperBoundaryExist() && linearFunction->getDomain()->lowerBoundaryExist()) {
//printf("last function ub = %f, new function lb = %f\n", lLinearFunctions.back()->getDomain()->getUpperBoundary(), linearFunction->getDomain()->getLowerBoundary());
if (vLinearFunctions.back()->getDomain()->getUpperBoundary() == linearFunction->getDomain()->getLowerBoundary()) {
vLinearFunctions.push_back(linearFunction);
#ifdef PRINT
printf(" - added function\n");
#endif // PRINT
return true;
}
}
}
#ifdef PRINT
printf(" - couldn't add function\n");
#endif // PRINT
return false;
}
//NOTE: Specific Function for CAH Project (DATE18)
//TODO: if(vMountedSensors.size() < maxNumOf_mountedSensors) als aller erste Abfrage machen ... noch bevor "SensorSlotOfAgent* sensorSlotOfAgent = new SensorSlotOfAgent();"
//TODO: delete object if it cannot added to vector
printf("couldn't be mounted in %s (id: %03u) connected with Look up Table %s (id: %03u)\n", agent->get_name(), agent->get_id(), confidence_validator->get_name(), confidence_validator->get_id());
printf(" > Could not mount Master Agent %s (id: %03u) in Slave Agent %s (id: %03u)\n", masteragent->get_name().c_str(), masteragent->get_id(), slaveagent->get_name().c_str(), slaveagent->get_id());