16 package emlab.gen.role.investment;
18 import org.springframework.beans.factory.annotation.Autowired;
20 import agentspring.role.Role;
21 import agentspring.role.RoleComponent;
25 import emlab.gen.role.AbstractEnergyProducerRole;
41 public Reps getReps() {
47 logger.info(
"Dismantling plants if out of merit");
51 long horizon = producer.getPastTimeHorizon();
53 double requiredProfit = producer.getDismantlingRequiredOperatingProfit();
54 if (calculateAveragePastOperatingProfit(plant, horizon) < requiredProfit) {
55 logger.info(
"Dismantling power plant because it has had an operating loss (incl O&M cost) on average in the last "
56 + horizon +
" years: " + plant);
58 plant.dismantlePowerPlant(getCurrentTick());
Iterable< PowerPlant > findOperationalPowerPlantsByOwner(@Param("owner") EnergyProducer owner,@Param("tick") long tick)