Loading...
Searching...
No Matches
atomTyper.h
Go to the documentation of this file.
// -*- Mode: C++; tab-width: 2; -*-
// vi: set ts=2:
//
#ifndef BALL_STRUCTURE_ATOMTYPER_H
#define BALL_STRUCTURE_ATOMTYPER_H
#ifndef BALL_DATATYPE_HASHSET_H
# include <BALL/DATATYPE/hashSet.h>
#endif
#ifndef BALL_DATATYPE_STRINGHASHMAP_H
# include <BALL/DATATYPE/stringHashMap.h>
#endif
#include <vector>
namespace BALL
{
using std::vector;
class Molecule;
class System;
class Atom;
class BALL_EXPORT AtomTyper
{
public:
BALL_CREATE(AtomTyper)
AtomTyper();
AtomTyper(const AtomTyper& t);
virtual ~AtomTyper() {};
bool setup(const String& filename);
virtual void assignTo(System& s);
void setAromaticRings(const vector<HashSet<Atom*> >& rings) { aromatic_rings_ = rings;}
void setRings(const vector<HashSet<Atom*> >& rings) { rings_ = rings;}
// just for debugging: computational times for the individual SMARTS expressions
static StringHashMap<float> rule_times;
protected:
void assignTo(Molecule& mol);
virtual void assignSpecificValues_(Atom&) {};
virtual bool specificSetup_() { return true;}
vector<String> names_;
vector<String> rules_;
vector<Index> types_;
// entries in the file for specificSetup_() :
vector<vector<String> > fields_;
// number for fields per line in the config file
Size number_expected_fields_;
vector<HashSet<Atom*> > rings_;
vector<HashSet<Atom*> > aromatic_rings_;
StringHashMap<vector<Position> > element_to_rules_;
HashSet<Atom*> atoms_;
};
} // namespace BALL
#endif // BALL_STRUCTURE_ATOMTYPER_H
BALL_EXPORT
#define BALL_EXPORT
Definition COMMON/global.h:50
BALL::AtomTyper::aromatic_rings_
vector< HashSet< Atom * > > aromatic_rings_
Definition atomTyper.h:93
BALL::AtomTyper::types_
vector< Index > types_
Definition atomTyper.h:87
BALL::AtomTyper::rings_
vector< HashSet< Atom * > > rings_
Definition atomTyper.h:92
BALL::AtomTyper::setRings
void setRings(const vector< HashSet< Atom * > > &rings)
Definition atomTyper.h:65
BALL::AtomTyper::fields_
vector< vector< String > > fields_
Definition atomTyper.h:89
BALL::AtomTyper::element_to_rules_
StringHashMap< vector< Position > > element_to_rules_
Definition atomTyper.h:94
BALL::AtomTyper::rules_
vector< String > rules_
Definition atomTyper.h:86
BALL::AtomTyper::setup
bool setup(const String &filename)
Setup with the given line based file with SMARTS expressions.
BALL::AtomTyper::assignTo
virtual void assignTo(System &s)
BALL::AtomTyper::specificSetup_
virtual bool specificSetup_()
Definition atomTyper.h:83
BALL::AtomTyper::rule_times
static StringHashMap< float > rule_times
Definition atomTyper.h:68
BALL::AtomTyper::assignTo
void assignTo(Molecule &mol)
BALL::AtomTyper::number_expected_fields_
Size number_expected_fields_
Definition atomTyper.h:91
BALL::AtomTyper::assignSpecificValues_
virtual void assignSpecificValues_(Atom &)
Definition atomTyper.h:78
BALL::AtomTyper::names_
vector< String > names_
Definition atomTyper.h:85
BALL::AtomTyper::setAromaticRings
void setAromaticRings(const vector< HashSet< Atom * > > &rings)
Definition atomTyper.h:62
BALL::AtomTyper::AtomTyper
AtomTyper()
BALL::AtomTyper::atoms_
HashSet< Atom * > atoms_
Definition atomTyper.h:95
BALL::Atom
Definition atom.h:90
BALL::HashSet
Definition hashSet.h:46
BALL::Molecule
Definition molecule.h:31
BALL::StringHashMap
Definition stringHashMap.h:42
BALL::String
Definition string.h:57
BALL::System
Definition KERNEL/system.h:40
BALL_CREATE
#define BALL_CREATE(name)
Definition create.h:62
hashSet.h
BALL
Definition constants.h:13
BALL::Size
BALL_SIZE_TYPE Size
Definition COMMON/global.h:114
stringHashMap.h