Ejemplo n.º 1
0
 @Override
 public boolean startsWith(Model mo) {
   if (getConstraint().isContinuous()) {
     boolean ret = discreteCheck(mo);
     if (ret) {
       Mapping map = mo.getMapping();
       for (VM vm : getVMs()) {
         if (map.isRunning(vm)) {
           privateNodes.add(map.getVMLocation(vm));
         }
       }
       for (Node n : map.getOnlineNodes()) {
         if (map.getRunningVMs(n).isEmpty()) {
           idleNodes.add(n);
         }
       }
     }
     return ret;
   }
   return true;
 }