00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef MS_QUANT_PARAMETERS_HPP
00018 #define MS_QUANT_PARAMETERS_HPP
00019
00020
00021 #include <string>
00022 #include <vector>
00023
00024 namespace msparser_internal {
00025 class ms_quant_xmlloader;
00026 }
00027
00028 namespace matrix_science {
00029 class ms_xml_schema;
00030 class ms_xml_parameter;
00031 class ms_xml_parameters;
00032
00038
00039 class MS_MASCOTRESFILE_API ms_quant_parameter: public ms_xml_parameter
00040 {
00041 friend class msparser_internal::ms_quant_xmlloader;
00042
00043 public:
00045 ms_quant_parameter();
00046
00048 ms_quant_parameter(const ms_quant_parameter& src);
00049
00051 virtual ~ms_quant_parameter();
00052
00054 void copyFrom(const ms_quant_parameter* right);
00055
00056 #ifndef SWIG
00057
00058 ms_quant_parameter& operator=(const ms_quant_parameter& right);
00059 #endif
00060
00061 virtual std::string getSchemaType() const;
00062
00064 virtual std::string getNameSchemaType() const;
00065
00067 virtual std::string getDescriptionSchemaType() const;
00068
00070 virtual std::string getValueSchemaType() const;
00071
00072 protected:
00073 virtual bool saveToXML_ParameterByNumber(msparser_internal::ms_XMLHelper &helper, msparser_internal::ms_XMLElement &rootEl) const;
00074
00075 };
00076
00078
00081 class MS_MASCOTRESFILE_API ms_quant_parameters: public ms_xml_parameters
00082 {
00083 friend class msparser_internal::ms_quant_xmlloader;
00084 public:
00086 ms_quant_parameters();
00087
00089 ms_quant_parameters(const ms_quant_parameters& src);
00090
00092 virtual ~ms_quant_parameters();
00093
00095 void defaultValues();
00096
00098 void copyFrom(const ms_quant_parameters* right);
00099
00100 #ifndef SWIG
00101
00102 ms_quant_parameters& operator=(const ms_quant_parameters& right);
00103 #endif
00104
00105 virtual std::string getSchemaType() const;
00106
00108 virtual int getNumberOfParameters() const;
00109
00111 virtual void clearParameters();
00112
00114 void appendParameter(const ms_quant_parameter *item);
00115
00117 const ms_quant_parameter * getParameterByNumber(const int idx) const;
00118
00120 const ms_quant_parameter * getParameterByName(const char *name) const;
00121
00123 bool updateParameterByNumber(const int idx, const ms_quant_parameter *param);
00124
00126 bool updateParameterByName(const char *name, const ms_quant_parameter *param);
00127
00129 virtual bool deleteParameterByNumber(const int idx);
00130
00132 virtual bool deleteParameterByName(const char *name);
00133
00135 virtual std::string getParameterSchemaType() const;
00136
00137 protected:
00138 virtual bool saveToXML_Parameters(msparser_internal::ms_XMLHelper &helper, msparser_internal::ms_XMLElement &rootEl) const;
00139
00140 private:
00141 typedef std::vector< ms_quant_parameter* > entries_vector;
00142 entries_vector _entries;
00143
00144 };
00145
00147
00148 }
00149
00150 #endif // MS_QUANT_PARAMETERS_HPP
00151
00152
00153