Copyright © 1996 by the Regents of the University of California.

Atom Interface

The Atom interface provides the base level functionality for the Atom class. Associated with each atom are the its name, its atomic number, and optionally its force-field classification (i.e., atom type). Typically, names do not have to be unique. The Atom interface depends on the Molecule interface. And it uses the Symbol and Element classes from the Molecule Toolkit support library. The Atom class functionality is extended by the Bond and CoordSet interfaces.

Atom Member Functions

Atom()
Atom(Symbol name, Element element)
Atom(Symbol name, Element element, const std::string &type)
Constructors. The optional arguments are the atom name, the atomic symbol, and the force-field classification (atom type).
Symbol name() const
Return the name of the atom.
void setName(Symbol s)
Set the name of the atom.
Element element() const
Return the atomic symbol of the atom.
void setElement(Element s)
Set the atomic symbol of the atom.
std::string type() const
Return the assigned atom type.
void setType(const std::string &t)
Set the atom type.

Implementations

Atom_default
The Atom_default implementation has a member datum for each possible constructor argument and makes all of the above member functions inline.

Greg Couch, UCSF Computer Graphics Laboratory