]> Repos - portaudio/commitdiff
cpp binding: make operator == and != const. thanks to Riot for this patch. ticket...
authorrbencina <rbencina@0f58301d-fd10-0410-b4af-bbb618454e57>
Tue, 20 Jan 2015 05:10:17 +0000 (05:10 +0000)
committerrbencina <rbencina@0f58301d-fd10-0410-b4af-bbb618454e57>
Tue, 20 Jan 2015 05:10:17 +0000 (05:10 +0000)
bindings/cpp/include/portaudiocpp/Device.hxx
bindings/cpp/include/portaudiocpp/SystemDeviceIterator.hxx
bindings/cpp/include/portaudiocpp/SystemHostApiIterator.hxx
bindings/cpp/source/portaudiocpp/Device.cxx
bindings/cpp/source/portaudiocpp/SystemDeviceIterator.cxx
bindings/cpp/source/portaudiocpp/SystemHostApiIterator.cxx

index ffde7aa8e33f54b6b2d2a950c65b00a0f92ce5be..cc248af3d266a172e1f12bed2fa3dd0688b0258a 100644 (file)
@@ -60,8 +60,8 @@ namespace portaudio
                bool isHostApiDefaultInputDevice() const; // extended\r
                bool isHostApiDefaultOutputDevice() const; // extended\r
 \r
-               bool operator==(const Device &rhs);\r
-               bool operator!=(const Device &rhs);\r
+               bool operator==(const Device &rhs) const;\r
+               bool operator!=(const Device &rhs) const;\r
 \r
                // host api reference\r
                HostApi &hostApi();\r
index 613fc3db51a025b48b3e71c25d05741d65efaa05..b395ede5518fafe99d2ba8e64cd83a87d88b49cf 100644 (file)
@@ -48,8 +48,8 @@ namespace portaudio
                DeviceIterator &operator--();\r
                DeviceIterator operator--(int);\r
 \r
-               bool operator==(const DeviceIterator &rhs);\r
-               bool operator!=(const DeviceIterator &rhs);\r
+               bool operator==(const DeviceIterator &rhs) const;\r
+               bool operator!=(const DeviceIterator &rhs) const;\r
 \r
        private:\r
                friend class System;\r
index b9b13b85eb73571d515839fad201e4d1ab0d4a47..431f87bbeac71c2bd87f4048db1abd44085b4e37 100644 (file)
@@ -45,8 +45,8 @@ namespace portaudio
                HostApiIterator &operator--();\r
                HostApiIterator operator--(int);\r
 \r
-               bool operator==(const HostApiIterator &rhs);\r
-               bool operator!=(const HostApiIterator &rhs);\r
+               bool operator==(const HostApiIterator &rhs) const;\r
+               bool operator!=(const HostApiIterator &rhs) const;\r
 \r
        private:\r
                friend class System;\r
index cd7eb7cbd65acb15aa9b549e5cccbd5f98b0aff3..1655bd4657b958b774938f879c3169a7e60dfbe9 100644 (file)
@@ -131,12 +131,12 @@ namespace portaudio
 \r
                // -------------------------------------------------------------------------------\r
 \r
-               bool Device::operator==(const Device &rhs)\r
+               bool Device::operator==(const Device &rhs) const\r
                {\r
                        return (index_ == rhs.index_);\r
                }\r
 \r
-               bool Device::operator!=(const Device &rhs)\r
+               bool Device::operator!=(const Device &rhs) const\r
                {\r
                        return !(*this == rhs);\r
                }\r
index c3c00f70e53c0b32b89065b77f8ea18b81deb097..93113840d840afc382687a6350a530842083485f 100644 (file)
@@ -44,12 +44,12 @@ namespace portaudio
 \r
        // -----------------------------------------------------------------------------------\r
 \r
-       bool System::DeviceIterator::operator==(const System::DeviceIterator &rhs)\r
+       bool System::DeviceIterator::operator==(const System::DeviceIterator &rhs) const\r
        {\r
                return (ptr_ == rhs.ptr_);\r
        }\r
 \r
-       bool System::DeviceIterator::operator!=(const System::DeviceIterator &rhs)\r
+       bool System::DeviceIterator::operator!=(const System::DeviceIterator &rhs) const\r
        {\r
                return !(*this == rhs);\r
        }\r
index f34ca40c939792a615894753bad11889fb78bf5a..c41b4cb307c5d512e8f1537f0b607bf6a0cff984 100644 (file)
@@ -44,12 +44,12 @@ namespace portaudio
 \r
        // -----------------------------------------------------------------------------------\r
 \r
-       bool System::HostApiIterator::operator==(const System::HostApiIterator &rhs)\r
+       bool System::HostApiIterator::operator==(const System::HostApiIterator &rhs) const\r
        {\r
                return (ptr_ == rhs.ptr_);\r
        }\r
 \r
-       bool System::HostApiIterator::operator!=(const System::HostApiIterator &rhs)\r
+       bool System::HostApiIterator::operator!=(const System::HostApiIterator &rhs) const\r
        {\r
                return !(*this == rhs);\r
        }\r