source: molecuilder/src/atom_graphnode.cpp@ c1b76e

Last change on this file since c1b76e was 2e2a70, checked in by Frederik Heber <heber@…>, 16 years ago

Refactored atom.cpp into multiple files.

After the class atom was refactored into multiple base classes that are inherited, these base classes are also all put into separate files. This is basically a preparatory step for the like-wise refactoring of class molecule into inherited base classes and splitting up (that is there done already). Finally, we will also separate the relations, i.e. not have "atom.hpp" included everywhere and use class atom, but rather the subclasses such as TrajectoryParticle and its header files only.
Signed-off-by: Frederik Heber <heber@…>

  • Property mode set to 100644
File size: 1.0 KB
Line 
1/*
2 * atom_graphnode.cpp
3 *
4 * Created on: Oct 19, 2009
5 * Author: heber
6 */
7
8#include "atom_graphnode.hpp"
9#include "verbose.hpp"
10
11/** Constructor of class GraphNode.
12 */
13GraphNode::GraphNode()
14{
15};
16
17/** Destructor of class GraphNode.
18 */
19GraphNode::~GraphNode()
20{
21};
22
23/** Output graph info of this atom.
24 * \param *out output stream
25 */
26void GraphNode::OutputGraphInfo(ofstream *out) const
27{
28 *out << Verbose(2) << "Atom " << Name << " is " << ((SeparationVertex) ? "a" : "not a") << " separation vertex, components are ";
29 OutputComponentNumber(out);
30 *out << " with Lowpoint " << LowpointNr << " and Graph Nr. " << GraphNr << "." << endl;
31};
32
33/** Output a list of flags, stating whether the bond was visited or not.
34 * Note, we make use of the last entry of the ComponentNr always being -1 if allocated.
35 * \param *out output stream for debugging
36 */
37void GraphNode::OutputComponentNumber(ofstream *out) const
38{
39 if (ComponentNr != NULL) {
40 for (int i=0; ComponentNr[i] != -1; i++)
41 *out << ComponentNr[i] << " ";
42 }
43};
44
Note: See TracBrowser for help on using the repository browser.