8#ifndef IMPATOM_ELEMENT_H
9#define IMPATOM_ELEMENT_H
11#include <IMP/atom/atom_config.h>
16#include <boost/unordered_map.hpp>
20IMPATOM_BEGIN_NAMESPACE
137 NUMBER_OF_ELEMENTS = 107
142inline size_t hash_value(Element e) {
return e; }
146class IMPATOMEXPORT ElementTable {
160 struct ElementString {
165 static ElementString element_strings_[];
166 static Float mass_[];
167 static boost::unordered_map<std::string, Element> string_2_element_;
168 static boost::unordered_map<Element, std::string> element_2_string_;
171IMPATOMEXPORT ElementTable& get_element_table();
Element get_element(const std::string &s) const
get element from the string name (PDB columns 77-78)
std::string get_name(Element e) const
get string name for Element
Float get_mass(Element e) const
get mass for Element
Exception definitions and assertions.
Logging and error reporting support.
Element
The various elements currently supported/known.
double Float
Basic floating-point value (could be float, double...).