ProteoWizard
Public Member Functions | Public Attributes | List of all members
SimpleAnalyzer Struct Reference
Inheritance diagram for SimpleAnalyzer:
pwiz::analysis::MSDataAnalyzer

Public Member Functions

 SimpleAnalyzer (size_t _index)
 
virtual void open (const DataInfo &dataInfo)
 start analysis of the data More...
 
virtual UpdateRequest updateRequested (const DataInfo &dataInfo, const SpectrumIdentity &entry) const
 
virtual void update (const DataInfo &dataInfo, const Spectrum &spectrum)
 
virtual void close (const DataInfo &dataInfo)
 end analysis of the data More...
 
- Public Member Functions inherited from pwiz::analysis::MSDataAnalyzer
virtual ~MSDataAnalyzer ()
 
virtual UpdateRequest updateRequested (const DataInfo &dataInfo, const SpectrumIdentity &spectrumIdentity) const
 ask analyzer if it wants an update More...
 
virtual void update (const DataInfo &dataInfo, const Spectrum &spectrum)
 analyze a single spectrum More...
 

Public Attributes

size_t index
 
bool opened
 
int updateCount
 
bool closed
 

Detailed Description

Definition at line 37 of file MSDataAnalyzerTest.cpp.

Constructor & Destructor Documentation

§ SimpleAnalyzer()

SimpleAnalyzer::SimpleAnalyzer ( size_t  _index)
inline

Definition at line 44 of file MSDataAnalyzerTest.cpp.

Member Function Documentation

§ open()

virtual void SimpleAnalyzer::open ( const DataInfo dataInfo)
inlinevirtual

start analysis of the data

Reimplemented from pwiz::analysis::MSDataAnalyzer.

Definition at line 46 of file MSDataAnalyzerTest.cpp.

47  {
48  // initialize everything, since Analyzers may be reused
49  opened = false;
50  updateCount = 0;
51  closed=false;
52 
53  // do something
54  opened = true;
55  }

§ updateRequested()

virtual UpdateRequest SimpleAnalyzer::updateRequested ( const DataInfo dataInfo,
const SpectrumIdentity &  entry 
) const
inlinevirtual

Definition at line 57 of file MSDataAnalyzerTest.cpp.

References UpdateRequest_NoBinary, and UpdateRequest_None.

59  {
60  // only request this->index
62  }
UpdateRequest_None
UpdateRequest_NoBinary
size_t index
the zero-based, consecutive index of the spectrum in the SpectrumList.
Definition: MSData.hpp:472

§ update()

virtual void SimpleAnalyzer::update ( const DataInfo dataInfo,
const Spectrum &  spectrum 
)
inlinevirtual

Definition at line 64 of file MSDataAnalyzerTest.cpp.

References os_.

66  {
67  if (os_) *os_ << "[" << index << "]" << " update: " << spectrum.index << endl;
68  updateCount++;
69  }
size_t index
the zero-based, consecutive index of the spectrum in the SpectrumList.
Definition: MSData.hpp:472
ostream * os_

§ close()

virtual void SimpleAnalyzer::close ( const DataInfo dataInfo)
inlinevirtual

end analysis of the data

Reimplemented from pwiz::analysis::MSDataAnalyzer.

Definition at line 71 of file MSDataAnalyzerTest.cpp.

71 {closed = true;}

Member Data Documentation

§ index

size_t SimpleAnalyzer::index

Definition at line 39 of file MSDataAnalyzerTest.cpp.

§ opened

bool SimpleAnalyzer::opened

Definition at line 40 of file MSDataAnalyzerTest.cpp.

Referenced by test().

§ updateCount

int SimpleAnalyzer::updateCount

Definition at line 41 of file MSDataAnalyzerTest.cpp.

Referenced by test().

§ closed

bool SimpleAnalyzer::closed

Definition at line 42 of file MSDataAnalyzerTest.cpp.

Referenced by test().


The documentation for this struct was generated from the following file: