Class InOrderScheduler

java.lang.Object
modelarium.scheduler.InOrderScheduler
All Implemented Interfaces:
ModelScheduler

public class InOrderScheduler extends Object implements ModelScheduler
A scheduler that executes each agent in the order they appear in the agent set.

This scheduling strategy ensures that all agents are processed sequentially and predictably for each simulation tick.

  • Constructor Details

    • InOrderScheduler

      public InOrderScheduler()
  • Method Details

    • runTick

      public void runTick(AgentSet agentSet)
      Executes each agent's run() method in the order they are stored in the agent set.
      Specified by:
      runTick in interface ModelScheduler
      Parameters:
      agentSet - the set of agents to run for this tick