Class SimulationTickClock

  • All Implemented Interfaces:
    IClock, ISimulationClock

    public class SimulationTickClock
    extends AbstractClock
    implements ISimulationClock
    A time-driven simulation clock represents a discrete clock that is based on ticks. This means that only time points can occur that are based on ticks (not in between ticks).
    • Constructor Detail

      • SimulationTickClock

        public SimulationTickClock​(java.lang.String name,
                                   long starttime,
                                   long delta)
        Create a new clock.
        Parameters:
        name - The name.
        starttime - The start time.
        delta - The time delta for time advance.
      • SimulationTickClock

        public SimulationTickClock​(IClock oldclock)
        Create a new clock.
        Parameters:
        oldclock - The old clock.
    • Method Detail

      • advanceEvent

        public boolean advanceEvent()
        Advance one event.
        Specified by:
        advanceEvent in interface ISimulationClock
        Returns:
        True, if clock could be advanced.
      • getType

        public java.lang.String getType()
        Get the clock type.
        Specified by:
        getType in interface IClock
        Returns:
        The clock type.