Gromacs  2024.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Classes | Public Types | Public Member Functions | Static Public Member Functions | Public Attributes
gmx::AnalysisDataModuleManager::Impl Class Reference

Description

Private implementation class for AnalysisDataModuleManager.

Classes

struct  ModuleInfo
 Stores information about an attached module. More...
 

Public Types

enum  State { eNotStarted, eInData, eInFrame, eFinished }
 Describes the current state of the notification methods. More...
 
typedef std::vector< ModuleInfoModuleList
 Shorthand for list of modules added to the data.
 

Public Member Functions

void checkModuleProperties (const IAnalysisDataModule &module) const
 Checks whether a module is compatible with the data properties. More...
 
void presentData (AbstractAnalysisData *data, IAnalysisDataModule *module) const
 Present data already added to the data object to a module. More...
 

Static Public Member Functions

static void checkModuleProperty (const IAnalysisDataModule &module, DataProperty property, bool bSet)
 Checks whether a module is compatible with a given data property. More...
 

Public Attributes

ModuleList modules_
 List of modules added to the data.
 
bool bDataProperty_ [eDataPropertyNR]
 Properties of the owning data for module checking.
 
bool bAllowMissing_
 true if all modules support missing data.
 
bool bSerialModules_
 true if there are modules that do not support parallel processing.
 
bool bParallelModules_
 true if there are modules that support parallel processing.
 
State state_
 Current state of the notification methods. More...
 
int currIndex_
 Index of currently active frame or the next frame if not in frame.
 

Member Enumeration Documentation

Describes the current state of the notification methods.

Enumerator
eNotStarted 

Initial state (nothing called).

eInData 

notifyDataStart() called, no frame in progress.

eInFrame 

notifyFrameStart() called, but notifyFrameFinish() not.

eFinished 

notifyDataFinish() called.

Member Function Documentation

void gmx::AnalysisDataModuleManager::Impl::checkModuleProperties ( const IAnalysisDataModule module) const

Checks whether a module is compatible with the data properties.

Parameters
[in]moduleModule to check.
Exceptions
APIErrorif module is not compatible with the data.

Does not currently check the actual data (e.g., missing values), but only the dimensionality and other preset properties of the data.

void gmx::AnalysisDataModuleManager::Impl::checkModuleProperty ( const IAnalysisDataModule module,
DataProperty  property,
bool  bSet 
)
static

Checks whether a module is compatible with a given data property.

Parameters
[in]moduleModule to check.
[in]propertyProperty to check.
[in]bSetValue of the property to check against.
Exceptions
APIErrorif module is not compatible with the data.
void gmx::AnalysisDataModuleManager::Impl::presentData ( AbstractAnalysisData data,
IAnalysisDataModule module 
) const

Present data already added to the data object to a module.

Parameters
[in]dataData object to read data from.
[in]moduleModule to present the data to.
Exceptions
APIErrorif module is not compatible with the data.
APIErrorif all data is not available through getDataFrame().
unspecifiedAny exception thrown by module in its data notification methods.

Uses getDataFrame() in data to access all data in the object, and calls the notification functions in module as if the module had been registered to the data object when the data was added.

Member Data Documentation

State gmx::AnalysisDataModuleManager::Impl::state_
mutable

Current state of the notification methods.

This is used together with currIndex_ for sanity checks on the input data; invalid call sequences trigger asserts. The state of these variables does not otherwise affect the behavior of this class; this is the reason they can be changed in const methods.Whether notifyDataStart() has been called.


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