Celeritas
0.5.0-56+6b053cd
|
Interface for updating states at the beginning of the simulation. More...
#include <ActionInterface.hh>
Public Member Functions | |
virtual void | begin_run (P const &, S< MemSpace::host > &)=0 |
Set host data at the beginning of a run. | |
virtual void | begin_run (P const &, S< MemSpace::device > &)=0 |
Set device data at the beginning of a run. | |
Public Member Functions inherited from celeritas::ActionInterface | |
virtual | ~ActionInterface () noexcept=0 |
Default destructor. | |
virtual ActionId | action_id () const =0 |
ID of this action for verification and ordering. | |
virtual std::string_view | label () const =0 |
Short unique label of the action. | |
virtual std::string_view | description () const =0 |
Description of the action. | |
Additional Inherited Members | |
Public Types inherited from celeritas::ActionTypeTraits< P, S > | |
using | CoreParams = P |
using | CoreStateHost = S< MemSpace::host > |
using | CoreStateDevice = S< MemSpace::device > |
using | SpanCoreStateHost = Span< S< MemSpace::host > *const > |
using | SpanCoreStateDevice = Span< S< MemSpace::device > *const > |
Protected Member Functions inherited from celeritas::ActionInterface | |
ActionInterface ()=default | |
CELER_DEFAULT_COPY_MOVE (ActionInterface) | |
Interface for updating states at the beginning of the simulation.
This is necessary for some classes that require deferred initialization (either to the class itself or the state), for example because it needs the number of total actions being run.
If the class itself–rather than the state–needs initialization, try to initialize in the constructor and avoid using this interface if possible.