Open Babel  3.0
bondtyper.h
Go to the documentation of this file.
1 /**********************************************************************
2 bondtyper.h - Bond typer to perceive connectivity and bond orders/types.
3 
4 Copyright (C) 2003-2005 by Geoffrey R. Hutchison
5 
6 This file is part of the Open Babel project.
7 For more information, see <http://openbabel.org/>
8 
9 This program is free software; you can redistribute it and/or modify
10 it under the terms of the GNU General Public License as published by
11 the Free Software Foundation version 2 of the License.
12 
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
17 ***********************************************************************/
18 
19 #ifndef OB_BONDTYPER_H
20 #define OB_BONDTYPER_H
21 
22 #include <openbabel/parsmart.h>
23 #include <openbabel/data.h>
24 
25 namespace OpenBabel
26 {
27 
28 // class introduction in bondtyper.cpp
29 // Used for "perceiving" bonds, e.g. in XYZ or QM files with no bond info.
30 class OBAPI OBBondTyper : public OBGlobalDataBase
31 {
33  std::vector<std::pair<OBSmartsPattern*, std::vector<int> > > _fgbonds;
34 public:
35  OBBondTyper();
36  ~OBBondTyper();
37 
39 
40  void ParseLine(const char*);
42  size_t GetSize() { return _fgbonds.size();}
44 
46 
47  void AssignFunctionalGroupBonds(OBMol &mol);
50 };
51 
52 }
53 
54 #endif // OB_BONDTYPER_H
55 
Molecule Class.
Definition: mol.h:118
Global data and resource file parsers.
size_t GetSize()
Definition: bondtyper.h:42
Assigns bond types for file formats without bond information.
Definition: bondtyper.h:30
Daylight SMARTS parser.
Base data table class, handles reading data files.
Definition: data.h:48
Global namespace for all Open Babel code.
Definition: alias.h:22