FixedTimeTerminationCondition.java |
package org.lucci.madhoc.simulation; public class FixedTimeTerminationCondition extends TerminationCondition { private int time; @Override public boolean applicationHasCompleted(Monitor app) { return app.getNetwork().getSimulation().getSimulatedTime() >= this.time; } public void configure() throws Throwable { this.time = getMonitor().getNetwork().getSimulation().getConfiguration().getInteger("simulation_simulated_duration"); } }