ProteoWizard
Pep2MzIdent.hpp
Go to the documentation of this file.
1//
2// $Id$
3//
4// Original author: Robert Burke <robert.burke@proteowizard.org>
5//
6// Copyright 2009 Spielberg Family Center for Applied Proteomics
7// University of Southern California, Los Angeles, California 90033
8//
9// Licensed under the Apache License, Version 2.0 (the "License");
10// you may not use this file except in compliance with the License.
11// You may obtain a copy of the License at
12//
13// http://www.apache.org/licenses/LICENSE-2.0
14//
15// Unless required by applicable law or agreed to in writing, software
16// distributed under the License is distributed on an "AS IS" BASIS,
17// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18// See the License for the specific language governing permissions and
19// limitations under the License.
20//
21
22#ifndef _PEP2MZIDENT_HPP_
23#define _PEP2MZIDENT_HPP_
24
25#include "IdentData.hpp"
26#include "KwCVMap.hpp"
30
31#include <vector>
32
33
34namespace pwiz{
35namespace identdata{
36
37using namespace pwiz::data::pepxml;
38typedef boost::shared_ptr<IdentData> IdentDataPtr;
39
40/// Translates data from a MinimumPepXML object into a IdentData
41/// object tree when a translation is known. The IdentData object
42/// initializes a cvList with the "MS" and "UO" elements.
43///
44/// The translate method is used to copy data. The clear method resets
45/// the IdentData object, null's out the MSMSPipelineAnalysis.
47{
48
49public:
50 /// Initialized the member variables. Also adds the "MS" and "UO"
51 /// CV's to the cvList.
53 IdentDataPtr result = IdentDataPtr(new IdentData()));
54
55 /// Resets the member variables.
56 void clear();
57
58 bool operator()(const MSMSPipelineAnalysis& pepxml, IdentDataPtr mzid);
59
60 /// Translates all known tags in the pepXML object tree into the
61 /// IdentData object tree. The resulting IdentDataPtr is returned.
63
64 /// Clears fields and then sets the _mspa field to the address of
65 /// mspa.
66 void setMspa(const MSMSPipelineAnalysis& mspa);
67
68 /// Returns the IdentDataPtr object. If a translation has not been
69 /// done, or if clear has been called, then an empty IdentData
70 /// will be return in the IdentDataPtr object.
72
73 void setDebug(bool debug);
74
75 bool getDebug() const;
76
77 void setVerbose(bool verbose);
78
79 bool getVerbose() const;
80
81 void addParamMap(std::vector<CVMapPtr>& map);
82
83 void setParamMap(std::vector<CVMapPtr>& map);
84
85 const std::vector<CVMapPtr>& getParamMap() const;
86
87private:
88 class Impl;
89 boost::shared_ptr<Impl> pimpl;
90
91};
92
93} // namespace identdata
94} // namespace pwiz
95
96
97#endif
#define PWIZ_API_DECL
Definition Export.hpp:32
Translates data from a MinimumPepXML object into a IdentData object tree when a translation is known.
const std::vector< CVMapPtr > & getParamMap() const
boost::shared_ptr< Impl > pimpl
Pep2MzIdent(const MSMSPipelineAnalysis &mspa, IdentDataPtr result=IdentDataPtr(new IdentData()))
Initialized the member variables.
void clear()
Resets the member variables.
void addParamMap(std::vector< CVMapPtr > &map)
void setParamMap(std::vector< CVMapPtr > &map)
IdentDataPtr translate()
Translates all known tags in the pepXML object tree into the IdentData object tree.
void setVerbose(bool verbose)
void setMspa(const MSMSPipelineAnalysis &mspa)
Clears fields and then sets the _mspa field to the address of mspa.
bool operator()(const MSMSPipelineAnalysis &pepxml, IdentDataPtr mzid)
IdentDataPtr getIdentData() const
Returns the IdentDataPtr object.
boost::shared_ptr< IdentData > IdentDataPtr
Implementation of the MzIdentMLType from the mzIdentML schema.