Scheduler Class Reference

#include <Scheduler.H>

List of all members.


Detailed Description

This class executes functions at periodic intervals during an AMR simulation.

Public Member Functions

 Scheduler ()
 Default constructor. Makes an empty schedule.
virtual ~Scheduler ()
 Destructor.
void schedule (RefCountedPtr< PeriodicFunction > a_function, int a_interval)
void schedule (RefCountedPtr< PeriodicFunction > a_function, Real a_interval)
void execute (int a_step, Real a_time) const
void setUp (AMR &a_AMR)
void conclude (int a_step, Real a_time) const

Private Member Functions

 Scheduler (const Scheduler &)
Scheduleroperator= (const Scheduler &)

Private Attributes

std::map< RefCountedPtr
< PeriodicFunction >, int,
PeriodicFunctionLessThan
m_stepTriggeredFunctions
std::map< RefCountedPtr
< PeriodicFunction >
, std::pair< Real, Real >
, PeriodicFunctionLessThan
m_timeTriggeredFunctions

Classes

class  PeriodicFunction
struct  PeriodicFunctionLessThan
 Ordering operator for pointers to periodic functions. More...

Constructor & Destructor Documentation

Scheduler::Scheduler (  ) 

Default constructor. Makes an empty schedule.

virtual Scheduler::~Scheduler (  )  [virtual]

Destructor.

Scheduler::Scheduler ( const Scheduler  )  [private]


Member Function Documentation

void Scheduler::schedule ( RefCountedPtr< PeriodicFunction a_function,
int  a_interval 
)

Add a periodic function that is called every a_interval steps.

Parameters:
a_function The function to be called periodically.
a_interval The number of steps that elapse between calls to a_function.

void Scheduler::schedule ( RefCountedPtr< PeriodicFunction a_function,
Real  a_interval 
)

Add a periodic function that is called every a_interval time units.

Parameters:
a_function The function to be called periodically.
a_interval The number of simulation time units that elapse between calls to a_function.

void Scheduler::execute ( int  a_step,
Real  a_time 
) const

Execute the schedule on the given step and at the given time.

Parameters:
a_step The step in the simulation at which the schedule is executed.
a_time The simulation time at which the schedule is executed.

void Scheduler::setUp ( AMR a_AMR  ) 

This function is called by the associated AMR object to set up interactions between itself and the periodic functions within the scheduler.

void Scheduler::conclude ( int  a_step,
Real  a_time 
) const

This function is called by the associated AMR object upon the conclusion of a simulation.

Parameters:
a_step The step in the simulation at which the schedule is executed.
a_time The simulation time at which the schedule is executed.

Scheduler& Scheduler::operator= ( const Scheduler  )  [private]


Member Data Documentation


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

Generated on Thu Nov 23 03:27:30 2017 for Chombo + EB + MF by  doxygen 1.5.5