00001
00002
00003
00004
00005
00006
00007 #ifndef BALL_MOLMEC_PARAMETER_RESIDUETORSIONS_H
00008 #define BALL_MOLMEC_PARAMETER_RESIDUETORSIONS_H
00009
00010 #ifndef BALL_FORMAT_PARAMETERSECTION_H
00011 # include <BALL/FORMAT/parameterSection.h>
00012 #endif
00013
00014 #ifndef BALL_MOLMEC_PARAMETER_ATOMTYPES_H
00015 # include <BALL/MOLMEC/PARAMETER/atomTypes.h>
00016 #endif
00017
00018 namespace BALL
00019 {
00032 class BALL_EXPORT ResidueTorsions
00033 : public ParameterSection
00034 {
00035 public:
00036
00040
00043 struct BALL_EXPORT Data
00044 {
00045 String residue_name;
00046 String atom_name_A;
00047 String atom_name_B;
00048 String atom_name_C;
00049 String atom_name_D;
00050
00051 Data(const String& name, const String& A, const String& B, const String& C, const String& D)
00052 : residue_name(name),
00053 atom_name_A(A),
00054 atom_name_B(B),
00055 atom_name_C(C),
00056 atom_name_D(D)
00057 {
00058 }
00059
00060 Data()
00061 : residue_name(""),
00062 atom_name_A(""),
00063 atom_name_B(""),
00064 atom_name_C(""),
00065 atom_name_D("")
00066 {
00067 }
00068
00069 bool operator == (const Data& data) const;
00070 bool operator != (const Data& data) const;
00071 };
00072
00074
00077
00080 ResidueTorsions();
00081
00084 virtual ~ResidueTorsions() ;
00085
00088 virtual void clear() ;
00089
00091
00094
00100 virtual bool extractSection(ForceFieldParameters& parameters, const String& section_name);
00101
00103 virtual bool extractSection(Parameters& parameters, const String& section_name);
00104
00107 Size getNumberOfResidueTorsions(const String& residue_name) const;
00108
00115 bool assignTorsion(const String& name, Position i, Data& torsion) const;
00116
00119 bool hasTorsion
00120 (const String& residue, const String& atom_A, const String& atom_B,
00121 const String& atom_C, const String& atom_D) const;
00122
00124
00125 protected:
00126
00127
00128
00129
00130
00131 StringHashMap<vector<Data> > torsions_;
00132
00133
00134
00135
00136
00137 HashSet<String> all_torsions_;
00138 };
00139 }
00140
00141 #endif // BALL_MOLMEC_PARAMETER_RESIDUETORSIONS_H