Gromacs  2019-beta2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Types | Public Member Functions
gmx::EnergyFrame Class Reference

#include <gromacs/trajectory/energyframe.h>

Description

Contains the content of an .edr frame read by an EnergyFrameReader.

The interface of this class is intended to resemble a subset of std::map.

Public Types

using MapType = std::map< std::string, real >
 Convenience type.
 
using MapConstIterator = MapType::const_iterator
 Convenience type.
 

Public Member Functions

 EnergyFrame (const t_enxframe &enxframe, std::map< std::string, int > indicesOfEnergyFields)
 Constructor.
 
std::string frameName () const
 Return string that helps users identify this frame, containing time and step number. More...
 
const realat (const std::string &name) const
 Return the value read for energy name. More...
 
MapConstIterator begin () const
 Return const interator to first element of values.
 
MapConstIterator end () const
 Return const interator to past the end element of values.
 
MapConstIterator find (const std::string &key) const
 Return a const interator to the element with key, or end() if not found.
 

Member Function Documentation

const real & gmx::EnergyFrame::at ( const std::string &  name) const

Return the value read for energy name.

Exceptions
APIErrorif name was not registered with EnergyFileReader.
std::string gmx::EnergyFrame::frameName ( ) const

Return string that helps users identify this frame, containing time and step number.

Exceptions
std::bad_allocwhen out of memory

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