Class SequentialDESimulator

java.lang.Object
org.simplesim.simulator.BasicSimulator
org.simplesim.simulator.SequentialDESimulator
All Implemented Interfaces:
Simulator
Direct Known Subclasses:
ConcurrentDESimulator

public class SequentialDESimulator extends BasicSimulator
Sequential simulator for discrete event models using a single threads

This simulator identifies all due agents of a model using a global event queue. Then the doEventSim method of these imminent agents is called sequentially.

Uses a SortedBucketQueue as default implementation of the global event queue

This implementation is especially useful to run DES models.

  • Constructor Details

    • SequentialDESimulator

      public SequentialDESimulator(BasicDomain root, EventQueue<Agent> queue, MessageForwardingStrategy forwarding)
      Constructs a new sequential simulator with given model, queue implementation and messaging strategy
      Parameters:
      root - the root domain of the model
      queue - the queue implementation to use as global event queue
      forwarding - the strategy to use for message forwarding
    • SequentialDESimulator

      public SequentialDESimulator(BasicDomain root)
      Quick start constructor of a sequential discrete-event simulator with a given model

      Uses RecursiveMessageForwarding and a HeapEventQueue as default options.

      Parameters:
      root - the root domain of the model
    • SequentialDESimulator

      public SequentialDESimulator(BasicDomain root, EventQueue<Agent> queue)
  • Method Details