The Gnome Chemistry Utils  0.14.0
Public Member Functions | Public Attributes | List of all members
gcu::FormulaResidue Class Reference

Residue. More...

#include <formula.h>

Inheritance diagram for gcu::FormulaResidue:
gcu::FormulaElt

Public Member Functions

 FormulaResidue (Residue const *res, char const *symbol, int Z)
virtual ~FormulaResidue ()
std::string Markup ()
std::string Text ()
void BuildRawFormula (std::map< int, int > &raw)
int GetValence ()
int GetZ (void) const
- Public Member Functions inherited from gcu::FormulaElt
 FormulaElt ()
virtual ~FormulaElt ()

Public Attributes

Residue const * residue
std::string Symbol
- Public Attributes inherited from gcu::FormulaElt
int stoich
unsigned start
unsigned end

Detailed Description

Residue.

class FormulaResidue gcu/formula.h Represents a residue in a formula.

Definition at line 236 of file formula.h.

Constructor & Destructor Documentation

gcu::FormulaResidue::FormulaResidue ( Residue const *  res,
char const *  symbol,
int  Z 
)
Parameters
resa gcu::Residue.
symbolthe atoms group symbol
Zthe atomic number of the element with the same symbol or 0.
virtual gcu::FormulaResidue::~FormulaResidue ( )
virtual

The destructor.

Member Function Documentation

void gcu::FormulaResidue::BuildRawFormula ( std::map< int, int > &  raw)
virtual
Parameters
rawwhere to put the result

Adds the number of atoms of each element to the map taking the stoichiometry coefficient into account.

Implements gcu::FormulaElt.

int gcu::FormulaResidue::GetValence ( )
virtual
Returns
the (most probable) valence of the element.

Implements gcu::FormulaElt.

gcu::FormulaResidue::GetZ ( void  ) const
inline
Returns
the atomic number of the element with the same symbol or 0.

Definition at line 279 of file formula.h.

std::string gcu::FormulaResidue::Markup ( )
virtual
Returns
the string representation of the element as a markup.

Reimplemented from gcu::FormulaElt.

std::string gcu::FormulaResidue::Text ( )
virtual
Returns
the string representation of the element as raw text.

Reimplemented from gcu::FormulaElt.

Member Data Documentation

Residue const* gcu::FormulaResidue::residue

The gcu::Residue correponding to the found symbol.

Definition at line 271 of file formula.h.

std::string gcu::FormulaResidue::Symbol

The symbol of the atoms group.

Definition at line 275 of file formula.h.


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