Gromacs  2025-dev-20241003-bd59e46
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Member Functions
gmx::SimulatorBuilder Class Reference

#include <gromacs/mdrun/simulatorbuilder.h>

Description

Class preparing the creation of Simulator objects.

Objects of this class build Simulator objects, which in turn are used to run molecular simulations.

Public Member Functions

 SimulatorBuilder ()
 Default constructor for SimulatorBuilder.
 
 ~SimulatorBuilder ()
 Default destructor for SimulatorBuilder.
 
void add (MembedHolder &&membedHolder)
 
void add (std::unique_ptr< StopHandlerBuilder > stopHandlerBuilder)
 
void add (SimulatorStateData &&simulatorStateData)
 
void add (SimulatorConfig &&simulatorConfig)
 
void add (SimulatorEnv &&simulatorEnv)
 
void add (Profiling &&profiling)
 
void add (ConstraintsParam &&constraintsParam)
 
void add (LegacyInput &&legacyInput)
 
void add (ReplicaExchangeParameters &&replicaExchangeParameters)
 
void add (InteractiveMD &&interactiveMd)
 
void add (SimulatorModules &&simulatorModules)
 
void add (CenterOfMassPulling &&centerOfMassPulling)
 
void add (IonSwapping &&ionSwapping)
 
void add (TopologyData &&topologyData)
 
void add (BoxDeformationHandle &&boxDeformation)
 
void add (std::unique_ptr< ReadCheckpointDataHolder > modularSimulatorCheckpointData)
 Pass the read checkpoint data for modular simulator. More...
 
std::unique_ptr< ISimulatorbuild (bool useModularSimulator)
 Build a Simulator object based on input data. More...
 

Member Function Documentation

void gmx::SimulatorBuilder::add ( std::unique_ptr< ReadCheckpointDataHolder modularSimulatorCheckpointData)

Pass the read checkpoint data for modular simulator.

Note that this is currently the point at which the ReadCheckpointDataHolder is fully filled. Consequently it stops being an object at which read operations from file are targeted, and becomes a read-only object from which elements read their data to recreate an earlier internal state.

Currently, this behavior change is not enforced. Once input reading and simulator builder have matured, these restrictions could be imposed.

See #3656

std::unique_ptr< ISimulator > gmx::SimulatorBuilder::build ( bool  useModularSimulator)

Build a Simulator object based on input data.

Build a Simulator object.

Return a pointer to a simulation object. The use of a parameter pack insulates the builder from changes to the arguments of the Simulator objects.

Exceptions
gmx::APIErrorif expected set-up methods have not been called before build()
Returns
Unique pointer to a Simulator object

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