@Test(expectedExceptions = {SchedulerException.class}) public void testWithUnknownVMs() throws SchedulerException { Model mo = new DefaultModel(); final VM vm1 = mo.newVM(); final VM vm2 = mo.newVM(); final VM vm3 = mo.newVM(); VM vm4 = mo.newVM(); VM vm5 = mo.newVM(); VM vm6 = mo.newVM(); Node n1 = mo.newNode(); Node n2 = mo.newNode(); Node n3 = mo.newNode(); Node n4 = mo.newNode(); mo.getMapping().on(n1, n2, n3).run(n1, vm1, vm4).run(n2, vm2).run(n3, vm3, vm5); SatConstraint cstr = mock(SatConstraint.class); when(cstr.getInvolvedVMs()).thenReturn(Arrays.asList(vm1, vm2, vm6)); when(cstr.getInvolvedNodes()).thenReturn(Arrays.asList(n1, n4)); ChocoScheduler cra = new DefaultChocoScheduler(); cra.solve(mo, Collections.singleton(cstr)); }
@Override public ReconfigurationPlan solve(Model mo, Collection<? extends SatConstraint> cstrs) throws SchedulerException { return solve(mo, cstrs, new MinMTTR()); }
DefaultChocoScheduler implements ChocoScheduler { @Override public ReconfigurationPlan solve(Model mo, Collection<? extends SatConstraint> cstrs) throws SchedulerException { return solve(mo, cstrs, new MinMTTR()); } }
DefaultChocoScheduler implements ChocoScheduler { @Override public ReconfigurationPlan solve(Model mo, Collection<? extends SatConstraint> cstrs) throws SchedulerException { return solve(mo, cstrs, new MinMTTR()); } DefaultChocoScheduler(Parameters ps);  DefaultChocoScheduler(); }
DefaultChocoScheduler implements ChocoScheduler { @Override public ReconfigurationPlan solve(Model mo, Collection<? extends SatConstraint> cstrs) throws SchedulerException { return solve(mo, cstrs, new MinMTTR()); } DefaultChocoScheduler(Parameters ps);  DefaultChocoScheduler(); @Override Parameters doOptimize(boolean b); @Override boolean doOptimize(); @Override Parameters setTimeLimit(int t); @Override int getTimeLimit(); @Override Parameters doRepair(boolean b); @Override boolean doRepair(); @Override ReconfigurationPlan solve(Model mo, Collection<? extends SatConstraint> cstrs); @Override ReconfigurationPlan solve(Instance i); @Override DefaultChocoScheduler setParameters(Parameters p); @Override Parameters getParameters(); @Override ChocoMapper getMapper(); @Override DurationEvaluators getDurationEvaluators(); @Override SolvingStatistics getStatistics(); @Override Parameters setMaxEnd(int end); @Override int getMaxEnd(); @Override Parameters setVerbosity(int lvl); @Override Parameters setMapper(ChocoMapper map); @Override Parameters setDurationEvaluators(DurationEvaluators d); @Override int getVerbosity(); @Override InstanceSolver getInstanceSolver(); @Override void setInstanceSolver(InstanceSolver p); @Override Parameters setTransitionFactory(TransitionFactory amf); @Override TransitionFactory getTransitionFactory(); @Override Parameters setRandomSeed(long s); @Override long getRandomSeed(); @Override boolean addChocoView(Class<? extends ChocoView> v); @Override boolean removeChocoView(Class<? extends ChocoView> v); @Override Settings chocoSettings(); @Override Parameters chocoSettings(Settings s); @Override List<Class<? extends ChocoView>> getChocoViews(); @Override EnvironmentFactory getEnvironmentFactory(); @Override Parameters setEnvironmentFactory(EnvironmentFactory f); @Override Parameters addSolutionListener(BiConsumer<ReconfigurationProblem, ReconfigurationPlan> consumer); @Override List<BiConsumer<ReconfigurationProblem, ReconfigurationPlan>> solutionListeners(); @Override void stop(); }
DefaultChocoScheduler implements ChocoScheduler { @Override public ReconfigurationPlan solve(Model mo, Collection<? extends SatConstraint> cstrs) throws SchedulerException { return solve(mo, cstrs, new MinMTTR()); } DefaultChocoScheduler(Parameters ps);  DefaultChocoScheduler(); @Override Parameters doOptimize(boolean b); @Override boolean doOptimize(); @Override Parameters setTimeLimit(int t); @Override int getTimeLimit(); @Override Parameters doRepair(boolean b); @Override boolean doRepair(); @Override ReconfigurationPlan solve(Model mo, Collection<? extends SatConstraint> cstrs); @Override ReconfigurationPlan solve(Instance i); @Override DefaultChocoScheduler setParameters(Parameters p); @Override Parameters getParameters(); @Override ChocoMapper getMapper(); @Override DurationEvaluators getDurationEvaluators(); @Override SolvingStatistics getStatistics(); @Override Parameters setMaxEnd(int end); @Override int getMaxEnd(); @Override Parameters setVerbosity(int lvl); @Override Parameters setMapper(ChocoMapper map); @Override Parameters setDurationEvaluators(DurationEvaluators d); @Override int getVerbosity(); @Override InstanceSolver getInstanceSolver(); @Override void setInstanceSolver(InstanceSolver p); @Override Parameters setTransitionFactory(TransitionFactory amf); @Override TransitionFactory getTransitionFactory(); @Override Parameters setRandomSeed(long s); @Override long getRandomSeed(); @Override boolean addChocoView(Class<? extends ChocoView> v); @Override boolean removeChocoView(Class<? extends ChocoView> v); @Override Settings chocoSettings(); @Override Parameters chocoSettings(Settings s); @Override List<Class<? extends ChocoView>> getChocoViews(); @Override EnvironmentFactory getEnvironmentFactory(); @Override Parameters setEnvironmentFactory(EnvironmentFactory f); @Override Parameters addSolutionListener(BiConsumer<ReconfigurationProblem, ReconfigurationPlan> consumer); @Override List<BiConsumer<ReconfigurationProblem, ReconfigurationPlan>> solutionListeners(); @Override void stop();  }