- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/Parser/PdbAtomInfoContainer.hpp
r4fbca9c r16462f 11 11 #include "PdbKey.hpp" 12 12 13 class Vector; 14 13 15 #include <string> 16 #include <typeinfo> 14 17 15 18 /** … … 22 25 23 26 // getter and setter 24 std::string get(const PdbKey::PdbDataKey key) const; 27 template <class T> T get(const PdbKey::PdbDataKey key) const { 28 switch (key) { 29 default : 30 std::cout << "Unknown key or not representable as " << typeid(T).name() << ": " << key << std::endl; 31 break; 32 } 33 return (T)NULL; 34 } 25 35 void set(const PdbKey::PdbDataKey key, std::string value); 26 36 … … 46 56 47 57 private: 58 std::string token; 48 59 int serial; 49 60 std::string name; 50 char alt loc;61 char altLoc; 51 62 std::string resName; 52 63 char chainID; 53 64 int resSeq; 54 65 char iCode; 66 Vector XYZ; 55 67 float occupancy; 56 68 float tempFactor; 69 std::string element; 57 70 int charge; 58 71 }; 59 72 73 template <> 74 std::string PdbAtomInfoContainer::get<std::string>(const PdbKey::PdbDataKey key) const; 75 template <> 76 int PdbAtomInfoContainer::get<int>(const PdbKey::PdbDataKey key) const; 77 template <> 78 double PdbAtomInfoContainer::get<double>(const PdbKey::PdbDataKey key) const; 79 60 80 #endif /* PDBATOMINFOCONTAINER_HPP_ */
Note:
See TracChangeset
for help on using the changeset viewer.