CYCLUS
Loading...
Searching...
No Matches
cyclus::TimeListener Class Referenceabstract

Detailed Description

The TimeListener class is an inheritable class for any Agent that requires knowlege of ticks and tocks.

The agent should register as a TimeListener with its context from its Deploy method. For Example:

MyFacility::Build(cyclus::Agent* parent) {
context()->RegisterTimeListener(this);
}
The abstract base class used by all types of agents that live and interact in a simulation.
Definition agent.h:49
virtual void Build(Agent *parent)
builds the facility in the simulation
Definition facility.cc:27

Definition at line 23 of file time_listener.h.

#include <time_listener.h>

Inheritance diagram for cyclus::TimeListener:
cyclus::Ider cyclus::Facility cyclus::Institution cyclus::Region cyclus::Dummy

Public Member Functions

virtual void Decision ()
 
virtual void Tick ()=0
 
virtual void Tock ()=0
 
- Public Member Functions inherited from cyclus::Ider
virtual const int id () const =0
 

Member Function Documentation

◆ Decision()

virtual void cyclus::TimeListener::Decision ( )
inlinevirtual

Simulation agents do their end-of-timestep decisions in the Decision method.

The decision method allows for agents to make decision based on the operation of facilities during the tick and tock of the current timestep. Facility operations should not occur during this phase.

Parameters
timeis the current simulation timestep

Definition at line 44 of file time_listener.h.

◆ Tick()

virtual void cyclus::TimeListener::Tick ( )
pure virtual

Simulation agents do their beginning-of-timestep activities in the Tick method.

Parameters
timeis the current simulation timestep

Implemented in cyclus::Institution, and cyclus::Region.

◆ Tock()

virtual void cyclus::TimeListener::Tock ( )
pure virtual

Simulation agents do their end-of-timestep activities in the Tock method.

Parameters
timeis the current simulation timestep

Implemented in cyclus::Institution, and cyclus::Region.


The documentation for this class was generated from the following file: