ProteoWizard
Public Member Functions | Public Attributes | List of all members
SelectedIndexPredicate Struct Reference
Inheritance diagram for SelectedIndexPredicate:
pwiz::analysis::ChromatogramList_Filter::Predicate

Public Member Functions

 SelectedIndexPredicate ()
 
virtual tribool accept (const ChromatogramIdentity &chromatogramIdentity) const
 return values: true: accept the Chromatogram false: reject the Chromatogram indeterminate: need to see the full Chromatogram object to decide More...
 
virtual bool done () const
 return true iff done accepting chromatograms; this allows early termination of the iteration through the original ChromatogramList, possibly using assumptions about the order of the iteration (e.g. More...
 
 SelectedIndexPredicate ()
 
virtual tribool accept (const Protein &protein) const
 
virtual bool done () const
 return true iff done accepting chromatograms; this allows early termination of the iteration through the original ChromatogramList, possibly using assumptions about the order of the iteration (e.g. More...
 
 SelectedIndexPredicate ()
 
virtual tribool accept (const SpectrumIdentity &spectrumIdentity) const
 
virtual bool done () const
 return true iff done accepting chromatograms; this allows early termination of the iteration through the original ChromatogramList, possibly using assumptions about the order of the iteration (e.g. More...
 
virtual string describe () const
 
- Public Member Functions inherited from pwiz::analysis::ChromatogramList_Filter::Predicate
virtual bool suggestedDetailLevel () const
 can be overridden in subclasses that know they will need a certain detail level; it must be overridden to return DetailLevel_FullData if binary data is needed More...
 
virtual boost::logic::tribool accept (const msdata::Chromatogram &chromatogram) const
 return true iff Chromatogram is accepted More...
 
virtual ~Predicate ()
 

Public Attributes

bool pastMaxIndex
 

Detailed Description

Definition at line 139 of file ChromatogramList_FilterTest.cpp.

Constructor & Destructor Documentation

◆ SelectedIndexPredicate() [1/3]

SelectedIndexPredicate::SelectedIndexPredicate ( )
inline

Definition at line 143 of file ChromatogramList_FilterTest.cpp.

143 : pastMaxIndex(false) {}

◆ SelectedIndexPredicate() [2/3]

SelectedIndexPredicate::SelectedIndexPredicate ( )
inline

Definition at line 80 of file ProteinList_FilterTest.cpp.

80 : pastMaxIndex(false) {}

◆ SelectedIndexPredicate() [3/3]

SelectedIndexPredicate::SelectedIndexPredicate ( )
inline

Definition at line 259 of file SpectrumList_FilterTest.cpp.

259 : pastMaxIndex(false) {}

Member Function Documentation

◆ accept() [1/3]

virtual tribool SelectedIndexPredicate::accept ( const ChromatogramIdentity chromatogramIdentity) const
inlinevirtual

return values: true: accept the Chromatogram false: reject the Chromatogram indeterminate: need to see the full Chromatogram object to decide

Implements pwiz::analysis::ChromatogramList_Filter::Predicate.

Definition at line 145 of file ChromatogramList_FilterTest.cpp.

146  {
147  if (chromatogramIdentity.index>2) pastMaxIndex = true;
148 
149  return (chromatogramIdentity.index==1 ||
150  chromatogramIdentity.index==2);
151  }

References pwiz::msdata::ChromatogramIdentity::index.

◆ done() [1/3]

virtual bool SelectedIndexPredicate::done ( ) const
inlinevirtual

return true iff done accepting chromatograms; this allows early termination of the iteration through the original ChromatogramList, possibly using assumptions about the order of the iteration (e.g.

index is increasing, nativeID interpreted as scan number is increasing, ...)

Reimplemented from pwiz::analysis::ChromatogramList_Filter::Predicate.

Definition at line 153 of file ChromatogramList_FilterTest.cpp.

154  {
155  return pastMaxIndex;
156  }

◆ accept() [2/3]

virtual tribool SelectedIndexPredicate::accept ( const Protein protein) const
inlinevirtual

Definition at line 82 of file ProteinList_FilterTest.cpp.

83  {
84  if (protein.index>5) pastMaxIndex = true;
85 
86  return (protein.index==1 ||
87  protein.index==3 ||
88  protein.index==5);
89  }

References pwiz::proteome::Protein::index.

◆ done() [2/3]

virtual bool SelectedIndexPredicate::done ( ) const
inlinevirtual

return true iff done accepting chromatograms; this allows early termination of the iteration through the original ChromatogramList, possibly using assumptions about the order of the iteration (e.g.

index is increasing, nativeID interpreted as scan number is increasing, ...)

Reimplemented from pwiz::analysis::ChromatogramList_Filter::Predicate.

Definition at line 91 of file ProteinList_FilterTest.cpp.

92  {
93  return pastMaxIndex;
94  }

◆ accept() [3/3]

virtual tribool SelectedIndexPredicate::accept ( const SpectrumIdentity spectrumIdentity) const
inlinevirtual

Definition at line 261 of file SpectrumList_FilterTest.cpp.

262  {
263  if (spectrumIdentity.index>5) pastMaxIndex = true;
264 
265  return (spectrumIdentity.index==1 ||
266  spectrumIdentity.index==3 ||
267  spectrumIdentity.index==5);
268  }

References pwiz::msdata::SpectrumIdentity::index.

◆ done() [3/3]

virtual bool SelectedIndexPredicate::done ( ) const
inlinevirtual

return true iff done accepting chromatograms; this allows early termination of the iteration through the original ChromatogramList, possibly using assumptions about the order of the iteration (e.g.

index is increasing, nativeID interpreted as scan number is increasing, ...)

Reimplemented from pwiz::analysis::ChromatogramList_Filter::Predicate.

Definition at line 270 of file SpectrumList_FilterTest.cpp.

271  {
272  return pastMaxIndex;
273  }

◆ describe()

virtual string SelectedIndexPredicate::describe ( ) const
inlinevirtual

Definition at line 275 of file SpectrumList_FilterTest.cpp.

275 { return ""; }

Member Data Documentation

◆ pastMaxIndex

bool SelectedIndexPredicate::pastMaxIndex
mutable

Definition at line 141 of file ChromatogramList_FilterTest.cpp.


The documentation for this struct was generated from the following files:
pwiz::msdata::SpectrumIdentity::index
size_t index
the zero-based, consecutive index of the spectrum in the SpectrumList.
Definition: MSData.hpp:473
SelectedIndexPredicate::pastMaxIndex
bool pastMaxIndex
Definition: ChromatogramList_FilterTest.cpp:141
pwiz::proteome::Protein::index
size_t index
Definition: ProteomeData.hpp:43
pwiz::msdata::ChromatogramIdentity::index
size_t index
the zero-based, consecutive index of the chromatogram in the ChromatogramList.
Definition: MSData.hpp:492