00001 #ifndef INCLUDED_PORTAUDIO_SYSTEMDEVICEITERATOR_HXX 00002 #define INCLUDED_PORTAUDIO_SYSTEMDEVICEITERATOR_HXX 00003 00004 // --------------------------------------------------------------------------------------- 00005 00006 #include <iterator> 00007 #include <cstddef> 00008 00009 #include "portaudiocpp/System.hxx" 00010 00011 // --------------------------------------------------------------------------------------- 00012 00013 // Forward declaration(s): 00014 namespace portaudio 00015 { 00016 class Device; 00017 class HostApi; 00018 } 00019 00020 // --------------------------------------------------------------------------------------- 00021 00022 // Declaration(s): 00023 namespace portaudio 00024 { 00025 00026 00034 class System::DeviceIterator 00035 { 00036 public: 00037 typedef std::bidirectional_iterator_tag iterator_category; 00038 typedef Device value_type; 00039 typedef ptrdiff_t difference_type; 00040 typedef Device * pointer; 00041 typedef Device & reference; 00042 00043 Device &operator*() const; 00044 Device *operator->() const; 00045 00046 DeviceIterator &operator++(); 00047 DeviceIterator operator++(int); 00048 DeviceIterator &operator--(); 00049 DeviceIterator operator--(int); 00050 00051 bool operator==(const DeviceIterator &rhs); 00052 bool operator!=(const DeviceIterator &rhs); 00053 00054 private: 00055 friend class System; 00056 friend class HostApi; 00057 Device **ptr_; 00058 }; 00059 00060 00061 } // namespace portaudio 00062 00063 // --------------------------------------------------------------------------------------- 00064 00065 #endif // INCLUDED_PORTAUDIO_SYSTEMDEVICEITERATOR_HXX 00066