Gromacs  2025-dev-20240614-602a366
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Member Functions
SimulationParticle Class Reference

#include <gromacs/topology/atoms.h>

Description

Single particle in a simulation.

Public Member Functions

void serializeParticle (gmx::ISerializer *serializer)
 Write info to serializer.
 
real m () const
 Access mass. A state.
 
real q () const
 Access charge. A state.
 
unsigned short type () const
 Access atom type. A state.
 
real mB () const
 Access mass. B state.
 
real qB () const
 Access charge. B state.
 
unsigned short typeB () const
 Access atom type. B state.
 
std::string particleName () const
 Access particle name.
 
std::string particleTypeNameA () const
 Access type name for state A.
 
std::string particleTypeNameB () const
 Access type name for state B if it exists.
 
ParticleType ptype () const
 Access particle type.
 
gmx::Index resind () const
 Access residue index.
 
int atomnumber () const
 Access atomic number.
 
std::string elem () const
 Access element name.
 
bool haveMass () const
 Do we have mass?
 
bool haveCharge () const
 Do we have charge?
 
bool haveType () const
 Do we have type?
 
bool haveParticleName () const
 Do we have particle name set?
 
bool haveParticleTypeName () const
 Do we have the particle type name set.
 
bool haveBStateForAll () const
 Do we have B state?
 
 SimulationParticle (const std::optional< ParticleMass > mass, const std::optional< ParticleCharge > charge, const std::optional< ParticleTypeValue > particleTypeValue, const std::optional< ParticleTypeName > particleTypeName, NameHolder particleName, ParticleType particleType, gmx::Index residueIndex, int atomicNumber, const std::string &elementName)
 Constructor with complete information. A and B states are equivalent.
 
 SimulationParticle (gmx::ISerializer *serializer, const StringTable &table)
 Construct new datastructure from deserialization.
 
 SimulationParticle (const SimulationParticle &)=default
 Copy constructor.
 
SimulationParticleoperator= (const SimulationParticle &)=default
 Copy assignment.
 
 SimulationParticle (SimulationParticle &&)=default
 Default move constructor.
 
SimulationParticleoperator= (SimulationParticle &&)=default
 Default move assignment.
 

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