MTK++ Latest version: 0.2.0

molParser.h
Go to the documentation of this file.
00001 
00035 #ifndef MOLPARSER_H
00036 #define MOLPARSER_H
00037 
00038 #include <map>
00039 #include <vector>
00040 #include <iostream>
00041 #include <string.h>
00042 #include <fstream>
00043 #include <iomanip>
00044 
00045 #include "baseParser.h"
00046 
00047 namespace MTKpp
00048 {
00049 
00050 class collection;
00051 class molecule;
00052 class submolecule;
00053 class atom;
00054 class element;
00055 class connections;
00056 struct Bond;
00057 struct Angle;
00058 struct Torsion;
00059 struct Improper;
00060 class vector3d;
00061 
00062 // ============================================================
00063 // Class : molParser()
00064 // ------------------------------------------------------------
00072 // ============================================================
00073 class molParser : public baseParser
00074 
00075 {
00076 public:
00077 
00081     molParser();
00082 
00084     ~molParser();
00085 
00092     void            Read(const std::string &i, molecule* m, const bool &bohr = false);
00093 
00100     void            Read(const std::string &i, collection* c, const bool &bohr = false);
00101 
00107     void            Write(const std::string &o, molecule* m);
00108 
00115     void            Write(const std::string &o, molecule* m, std::vector< vector3d > &coordinates);
00116 
00123     void            Write(const std::string &o, collection* c, const int &molID);
00124 
00125 protected: // functions
00126 
00128 
00132     bool            ReadAtomLine(std::string &fileline, AtomLine* pthisAtom);
00133 
00135 
00138     int             getAtom(int i);
00139 
00140 protected: //data
00141 
00143     // - pointers to the backbone objects - //
00145 
00147     molecule*       pMolecule;
00148 
00150     submolecule* pSubMolecule;
00151 
00153     atom*           pAtom;
00154 
00156     Bond*           pBond;
00157 
00159     atom*           pBondAtom1;
00160 
00162     atom*           pBondAtom2;
00163 
00165     std::map<int, int>   itsAtomMap;
00166 
00167     // connections pointer
00168     connections* pConnections;
00169 };
00170 
00171 } // MTKpp namespace
00172 
00173 #endif // MOLPARSER_H

Generated on Fri Dec 23 2011 09:28:51 for MTK++ by Doxygen 1.7.5.1