Package com.amalgamasimulation.engine
Interface Agent
- All Superinterfaces:
Timeable
- All Known Implementing Classes:
GraphAgent,LongAgent,LongAgentTail,Train
Base type of all agent classes
- Author:
- Andrey Malykhanov
-
Method Summary
Modifier and TypeMethodDescriptiondefault LocalDateTimeReturns the begin date, i.e.engine()Returns the reference to theEnginethat is used to simulate this agent's behaviorgetName()Returns the name of this agentdefault doubletime()Returns the current simulation timedefault ChronoUnittimeUnit()Returns the simulation time unit, i.e.Methods inherited from interface com.amalgamasimulation.utils.time.Timeable
dateToTime, dateToTime, day, duration, hour, minute, second, timeToDate, week, wholeDays, wholeDays, wholeHours, wholeHours, wholeUnits
-
Method Details
-
getName
String getName()Returns the name of this agent- Returns:
- name of this agent
-
engine
Engine engine()Returns the reference to theEnginethat is used to simulate this agent's behavior- Returns:
- reference to the
Enginethat is used to simulate this agent's behavior
-
time
default double time()Returns the current simulation time- Returns:
- current simulation time
-
beginDate
Description copied from interface:TimeableReturns the begin date, i.e. the simulation date that corresponds to zero simulation time -
timeUnit
Description copied from interface:TimeableReturns the simulation time unit, i.e. period unit that corresponds to one unit of simulation time
-