ProteoWizard
Serializer_FASTA.hpp
Go to the documentation of this file.
1//
2// $Id$
3//
4//
5// Original author: Matt Chambers <matt.chambers .@. vanderbilt.edu>
6//
7// Copyright 2009 Vanderbilt University - Nashville, TN 37232
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
23#ifndef _SERIALIZER_FASTA_HPP_
24#define _SERIALIZER_FASTA_HPP_
25
26
28#include "ProteomeData.hpp"
31
32
33namespace pwiz {
34namespace proteome {
35
36
37/// ProteomeData <-> FASTA stream serialization
39{
40 public:
41
42 /// Serializer_FASTA configuration
44 {
46
47 Config() : indexPtr(new data::MemoryIndex) {}
48 };
49
50 Serializer_FASTA(const Config& config = Config());
51
52 /// write ProteomeData object to ostream as FASTA
53 void write(std::ostream& os, const ProteomeData& pd,
54 const pwiz::util::IterationListenerRegistry* iterationListenerRegistry) const;
55
56 /// read in ProteomeData object from a FASTA istream
57 void read(boost::shared_ptr<std::istream> is, ProteomeData& pd) const;
58
59 private:
63};
64
65
66} // namespace proteome
67} // namespace pwiz
68
69
70#endif // _SERIALIZER_FASTA_HPP_
71
#define PWIZ_API_DECL
Definition Export.hpp:32
ProteomeData <-> FASTA stream serialization.
Serializer_FASTA(const Config &config=Config())
void read(boost::shared_ptr< std::istream > is, ProteomeData &pd) const
read in ProteomeData object from a FASTA istream
Serializer_FASTA & operator=(Serializer_FASTA &)
void write(std::ostream &os, const ProteomeData &pd, const pwiz::util::IterationListenerRegistry *iterationListenerRegistry) const
write ProteomeData object to ostream as FASTA
Serializer_FASTA(Serializer_FASTA &)
handles registration of IterationListeners and broadcast of update messages
boost::shared_ptr< Index > IndexPtr
Definition Index.hpp:72
Serializer_FASTA configuration.