public class SimpleEventCalendar extends Object implements EventCalendar
Modifier and Type | Field and Description |
---|---|
protected ClockReader |
clockReader |
protected Comparator<SimulationEvent> |
eventComparator |
protected List<SimulationEvent> |
eventList |
protected int |
minIndex |
Constructor and Description |
---|
SimpleEventCalendar(ClockReader clockReader,
Comparator<SimulationEvent> eventComparator) |
Modifier and Type | Method and Description |
---|---|
void |
addEvent(SimulationEvent event) |
void |
addEvents(Collection<SimulationEvent> simulationEvents) |
void |
clear() |
List<SimulationEvent> |
getEvents() |
boolean |
isEmpty() |
SimulationEvent |
peekFirstEvent() |
SimulationEvent |
removeFirstEvent() |
protected List<SimulationEvent> eventList
protected int minIndex
protected Comparator<SimulationEvent> eventComparator
protected final ClockReader clockReader
public SimpleEventCalendar(ClockReader clockReader, Comparator<SimulationEvent> eventComparator)
public boolean isEmpty()
isEmpty
in interface EventCalendar
public SimulationEvent peekFirstEvent()
peekFirstEvent
in interface EventCalendar
public SimulationEvent removeFirstEvent()
removeFirstEvent
in interface EventCalendar
public List<SimulationEvent> getEvents()
getEvents
in interface EventCalendar
public void addEvent(SimulationEvent event)
addEvent
in interface EventCalendar
public void clear()
clear
in interface EventCalendar
public void addEvents(Collection<SimulationEvent> simulationEvents)
Copyright © 2016 Alfresco. All rights reserved.