Audacity 3.2.0
Classes | Public Types | Public Member Functions | Private Attributes | Friends | List of all members
ExportPluginRegistry::ConstIterator Class Referencefinal

#include <ExportPluginRegistry.h>

Classes

struct  ProxyPtr
 

Public Types

using value_type = const std::tuple< ExportPlugin *, int >
 
using iterator_category = std::input_iterator_tag
 
using difference_type = int
 
using pointer = ProxyPtr
 
using reference = value_type
 

Public Member Functions

 ConstIterator (ExportPlugins::const_iterator pluginIt, int formatIndex)
 
reference operator* () const
 
pointer operator-> () const
 
ConstIteratoroperator++ ()
 
ConstIterator operator++ (int)
 

Private Attributes

ExportPlugins::const_iterator mPluginIt
 
int mFormatIndex
 

Friends

bool operator== (const ConstIterator &a, const ConstIterator &b)
 
bool operator!= (const ConstIterator &a, const ConstIterator &b)
 

Detailed Description

Definition at line 25 of file ExportPluginRegistry.h.

Member Typedef Documentation

◆ difference_type

Definition at line 41 of file ExportPluginRegistry.h.

◆ iterator_category

Definition at line 40 of file ExportPluginRegistry.h.

◆ pointer

Definition at line 42 of file ExportPluginRegistry.h.

◆ reference

Definition at line 43 of file ExportPluginRegistry.h.

◆ value_type

Definition at line 30 of file ExportPluginRegistry.h.

Constructor & Destructor Documentation

◆ ConstIterator()

ExportPluginRegistry::ConstIterator::ConstIterator ( ExportPlugins::const_iterator  pluginIt,
int  formatIndex 
)
inline

Definition at line 45 of file ExportPluginRegistry.h.

46 : mPluginIt(std::move(pluginIt)), mFormatIndex(formatIndex) { }
ExportPlugins::const_iterator mPluginIt

Member Function Documentation

◆ operator*()

reference ExportPluginRegistry::ConstIterator::operator* ( ) const
inline

Definition at line 48 of file ExportPluginRegistry.h.

48{ return std::make_tuple(mPluginIt->get(), mFormatIndex); }

◆ operator++() [1/2]

ExportPluginRegistry::ConstIterator & ExportPluginRegistry::ConstIterator::operator++ ( )

Definition at line 24 of file ExportPluginRegistry.cpp.

25{
27 if(mFormatIndex >= (*mPluginIt)->GetFormatCount())
28 {
29 mFormatIndex = 0;
30 ++mPluginIt;
31 }
32 return *this;
33}

◆ operator++() [2/2]

ConstIterator ExportPluginRegistry::ConstIterator::operator++ ( int  )
inline

Definition at line 54 of file ExportPluginRegistry.h.

55 {
56 auto prev = *this;
57 ++*this;
58 return prev;
59 }

◆ operator->()

pointer ExportPluginRegistry::ConstIterator::operator-> ( ) const
inline

Definition at line 50 of file ExportPluginRegistry.h.

50{ return ProxyPtr { std::make_tuple(mPluginIt->get(), mFormatIndex) }; }

Friends And Related Function Documentation

◆ operator!=

bool operator!= ( const ConstIterator a,
const ConstIterator b 
)
friend

Definition at line 66 of file ExportPluginRegistry.h.

67 {
68 return a.mPluginIt != b.mPluginIt || a.mFormatIndex != b.mFormatIndex;
69 }
std::vector< bool >::const_iterator a

◆ operator==

bool operator== ( const ConstIterator a,
const ConstIterator b 
)
friend

Definition at line 61 of file ExportPluginRegistry.h.

62 {
63 return a.mPluginIt == b.mPluginIt && a.mFormatIndex == b.mFormatIndex;
64 }

Member Data Documentation

◆ mFormatIndex

int ExportPluginRegistry::ConstIterator::mFormatIndex
private

Definition at line 28 of file ExportPluginRegistry.h.

◆ mPluginIt

ExportPlugins::const_iterator ExportPluginRegistry::ConstIterator::mPluginIt
private

Definition at line 27 of file ExportPluginRegistry.h.


The documentation for this class was generated from the following files: