00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef MS_QUANT_COMPONENT_HPP
00018 #define MS_QUANT_COMPONENT_HPP
00019
00020
00021 #include <string>
00022 #include <vector>
00023
00024
00025 namespace msparser_internal {
00026 class ms_quant_xmlloader;
00027 }
00028
00029 namespace matrix_science {
00030
00031 class ms_quant_modgroup;
00032 class ms_quant_moverz;
00033 class ms_quant_correction;
00034 class ms_quant_isotope;
00035 class ms_quant_satellite;
00036 class ms_xml_schema;
00037
00043
00044
00047 class MS_MASCOTRESFILE_API ms_quant_component: public ms_xml_IValidatable
00048 {
00049 friend class msparser_internal::ms_quant_xmlloader;
00050
00051 public:
00053 ms_quant_component();
00054
00056 ms_quant_component(const ms_quant_component& src);
00057
00059 virtual ~ms_quant_component();
00060
00062 void defaultValues();
00063
00065 void copyFrom(const ms_quant_component* right);
00066
00067 #ifndef SWIG
00068
00069 ms_quant_component& operator=(const ms_quant_component& right);
00070 #endif
00071
00073 virtual std::string getSchemaType() const;
00074
00076 virtual std::string validateShallow(const ms_xml_schema *pSchemaFileObj) const;
00077
00079 virtual std::string validateDeep(const ms_xml_schema *pSchemaFileObj) const;
00080
00081
00083 bool haveMoverz() const;
00084
00086 const ms_quant_moverz* getMoverz() const;
00087
00089 void setMoverz(const ms_quant_moverz* moverz);
00090
00092 void dropMoverz();
00093
00095 std::string getMoverzSchemaType() const;
00096
00097
00099 int getNumberOfModificationGroups() const;
00100
00102 void clearModificationGroups();
00103
00105 void appendModificationGroup(const ms_quant_modgroup *item);
00106
00108 const ms_quant_modgroup * getModificationGroupByNumber(const int idx) const;
00109
00111 const ms_quant_modgroup * getModificationGroupByName(const char *name) const;
00112
00114 bool updateModificationGroupByNumber(const int idx, const ms_quant_modgroup* modgroup);
00115
00117 bool updateModificationGroupByName(const char *name, const ms_quant_modgroup* modgroup);
00118
00120 bool deleteModificationGroupByNumber(const int idx);
00121
00123 bool deleteModificationGroupByName(const char *name);
00124
00126 std::string getModificationGroupSchemaType() const;
00127
00128
00130 int getNumberOfIsotopes() const;
00131
00133 void clearIsotopes();
00134
00136 void appendIsotope(const ms_quant_isotope* isotope);
00137
00139 const ms_quant_isotope* getIsotope(const int idx) const;
00140
00142 bool updateIsotope(const int idx, const ms_quant_isotope* isotope);
00143
00145 bool deleteIsotope(const int idx);
00146
00148 std::string getIsotopeSchemaType() const;
00149
00150
00151
00153 bool haveFileIndex() const;
00154
00156 int getFileIndex() const;
00157
00159 void setFileIndex(const int file_index);
00160
00162 void dropFileIndex();
00163
00165 std::string getFileIndexSchemaType() const;
00166
00167
00169 int getNumberOfCorrections() const;
00170
00172 void clearCorrections();
00173
00175 void appendCorrection(const ms_quant_correction* correction);
00176
00178 const ms_quant_correction* getCorrection(const int idx) const;
00179
00181 bool updateCorrection(const int idx, const ms_quant_correction* isotope);
00182
00184 bool deleteCorrection(const int idx);
00185
00187 std::string getCorrectionSchemaType() const;
00188
00189
00191 bool haveName() const;
00192
00194 std::string getName() const;
00195
00197 void setName(const char* value);
00198
00200 void dropName();
00201
00203 std::string getNameSchemaType() const;
00204
00205
00207 bool haveSatellite() const;
00208
00210 const ms_quant_satellite* getSatellite() const;
00211
00213 void setSatellite(const ms_quant_satellite* satellite);
00214
00216 void dropSatellite();
00217
00219 std::string getSatelliteSchemaType() const;
00220
00221 private:
00222
00223 ms_quant_moverz *_pMoverz;
00224 bool _moverz_set;
00225
00226 typedef std::vector< ms_quant_modgroup* > modgroup_vector;
00227 modgroup_vector _modgroups;
00228
00229 typedef std::vector< ms_quant_isotope* > isotope_vector;
00230 isotope_vector _isotopes;
00231
00232 int _fileIndex;
00233 bool _fileIndex_set;
00234
00235 typedef std::vector< ms_quant_correction* > correction_vector;
00236 correction_vector _corrections;
00237
00238
00239 std::string _name;
00240 bool _name_set;
00241
00242 ms_quant_satellite *_pSatellite;
00243 bool _satellite_set;
00244 };
00245
00247
00248 }
00249
00250 #endif // MS_QUANT_COMPONENT_HPP
00251
00252
00253