BALL 1.5.0
Public Types | Public Member Functions | List of all members
BALL::MolecularGraph Class Reference

#include <BALL/DATATYPE/GRAPH/molecularGraph.h>

Inheritance diagram for BALL::MolecularGraph:
MolecularGraphBase

Public Types

enum  ExportOptions { INCLUDE_ALL = -1 }
 @TODO do something useful with this More...
 
typedef boost::graph_traits< MolecularGraph >::vertex_descriptor Vertex
 
typedef boost::graph_traits< MolecularGraph >::edge_descriptor Edge
 
typedef boost::graph_traits< MolecularGraph >::vertex_iterator VertexIterator
 
typedef boost::graph_traits< MolecularGraph >::edge_iterator EdgeIterator
 
typedef boost::property_map< MolecularGraphBase, boost::vertex_atom_ptr_t >::type AtomPtrMap
 
typedef boost::property_map< MolecularGraphBase, boost::edge_bond_ptr_t >::type BondPtrMap
 
typedef boost::property_map< MolecularGraphBase, boost::vertex_atom_ptr_t >::const_type ConstAtomPtrMap
 
typedef boost::property_map< MolecularGraphBase, boost::edge_bond_ptr_t >::const_type ConstBondPtrMap
 
typedef GRAPH::GraphTraits< MolecularGraph >::EditableGraph EditableGraph
 

Public Member Functions

 MolecularGraph (AtomContainer &ac, ExportOptions opt=INCLUDE_ALL)
 
const EdgegetEdge (const Bond *bond) const
 
const VertexgetVertex (const Atom *atom) const
 
void editableCopy (EditableGraph &eg)
 

Detailed Description

This class provides a boost graph library representation of the molecular graph. It takes an AtomContainer as an input and creates an undirected graph modelling the atom connectivity. Bonds pointing into another atom container will be omited. The vertices of the graph are labeled with pointers to the original atoms; The edges are labeled with pointers to the original bonds.

These properties can be obtained by using the following code:

AtomPtrMap atom_ptrs = get(boost::vertex_atom_ptr, graph);
const Atom* atom = boost::get(atom_ptrs, vertex_handle);
@ vertex_atom_ptr
boost::property_map< MolecularGraphBase, boost::vertex_atom_ptr_t >::type AtomPtrMap

Definition at line 46 of file molecularGraph.h.

Member Typedef Documentation

◆ AtomPtrMap

Definition at line 58 of file molecularGraph.h.

◆ BondPtrMap

Definition at line 59 of file molecularGraph.h.

◆ ConstAtomPtrMap

Definition at line 60 of file molecularGraph.h.

◆ ConstBondPtrMap

Definition at line 61 of file molecularGraph.h.

◆ Edge

typedef boost::graph_traits<MolecularGraph>::edge_descriptor BALL::MolecularGraph::Edge

Definition at line 54 of file molecularGraph.h.

◆ EdgeIterator

typedef boost::graph_traits<MolecularGraph>::edge_iterator BALL::MolecularGraph::EdgeIterator

Definition at line 57 of file molecularGraph.h.

◆ EditableGraph

Definition at line 63 of file molecularGraph.h.

◆ Vertex

typedef boost::graph_traits<MolecularGraph>::vertex_descriptor BALL::MolecularGraph::Vertex

Definition at line 53 of file molecularGraph.h.

◆ VertexIterator

typedef boost::graph_traits<MolecularGraph>::vertex_iterator BALL::MolecularGraph::VertexIterator

Definition at line 56 of file molecularGraph.h.

Member Enumeration Documentation

◆ ExportOptions

@TODO do something useful with this

Enumerator
INCLUDE_ALL 

Definition at line 51 of file molecularGraph.h.

Constructor & Destructor Documentation

◆ MolecularGraph()

BALL::MolecularGraph::MolecularGraph ( AtomContainer ac,
ExportOptions  opt = INCLUDE_ALL 
)

Member Function Documentation

◆ editableCopy()

void BALL::MolecularGraph::editableCopy ( EditableGraph eg)

◆ getEdge()

const Edge & BALL::MolecularGraph::getEdge ( const Bond bond) const

◆ getVertex()

const Vertex & BALL::MolecularGraph::getVertex ( const Atom atom) const