Class WeeklyCityCheckTask
- java.lang.Object
-
- ch.sahits.game.openpatrician.model.event.TimedTask
-
- ch.sahits.game.openpatrician.engine.event.task.WeeklyCityCheckTask
-
- All Implemented Interfaces:
java.lang.Runnable
public class WeeklyCityCheckTask extends TimedTask
Timed task to for weekly checks. Created by andi on 20.03.17.
-
-
Field Summary
Fields Modifier and Type Field Description private CitiesState
citiesState
private org.springframework.context.ApplicationContext
context
private Date
date
private PlayerInteractionFactory
interactionFactory
private CityProductionAndConsumptionService
productionAndConsumtionService
private ServerSideTaskFactory
taskFactory
private TimedUpdatableTaskList
taskList
-
Constructor Summary
Constructors Constructor Description WeeklyCityCheckTask()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private java.time.LocalDateTime
getScheduledDateWeeklyUpdate()
private void
handleWeeklyUpdates()
private void
initialize()
void
run()
private void
scheduleNextWeekUpdate()
java.lang.String
toString()
-
-
-
Field Detail
-
date
@Autowired private Date date
-
taskList
@Autowired private TimedUpdatableTaskList taskList
-
taskFactory
@Autowired private ServerSideTaskFactory taskFactory
-
citiesState
@Autowired private CitiesState citiesState
-
productionAndConsumtionService
@Autowired private CityProductionAndConsumptionService productionAndConsumtionService
-
interactionFactory
@Autowired private PlayerInteractionFactory interactionFactory
-
context
@Autowired private org.springframework.context.ApplicationContext context
-
-
Method Detail
-
initialize
@PostConstruct private void initialize()
-
getScheduledDateWeeklyUpdate
private java.time.LocalDateTime getScheduledDateWeeklyUpdate()
-
run
public void run()
-
handleWeeklyUpdates
private void handleWeeklyUpdates()
-
scheduleNextWeekUpdate
private void scheduleNextWeekUpdate()
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-