<NME> support.hpp
<BEF> /*
 * OCILIB - C Driver for Oracle (C Wrapper for Oracle OCI)
 *
 * Website: http://www.ocilib.net
 *
 * Copyright (c) 2007-2021 Vincent ROGIER <vince.rogier@ocilib.net>
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

#pragma once

#include "ocilibcpp/core.hpp"

// ReSharper disable CppClangTidyModernizeUseNodiscard
// ReSharper disable CppClangTidyHicppUseEqualsDefault
// ReSharper disable CppClangTidyHicppSpecialMemberFunctions
// ReSharper disable CppClangTidyCppcoreguidelinesSpecialMemberFunctions
// ReSharper disable CppClangTidyModernizePassByValue

namespace ocilib
{
    /**
     * @namespace ocilib::support
     * @brief OCILIB internal support classes 
     *
        {
        public:

            BindObject(const Statement& statement, const ostring& name, unsigned int mode);

            virtual ~BindObject() noexcept;

            ostring GetName() const;

            Statement GetStatement() const;

            unsigned int GetMode() const;

        */ 
        class BindObject

        protected:

            const Statement& _statement;
            ostring _name;
            unsigned int _mode;
        };
            ostring GetName() const;

        {
        public:

            BindArray(const Statement& statement, const ostring& name, unsigned int mode);
            virtual ~BindArray() noexcept;

            template<class T>
        protected:

            const ocilib::Statement& _statement;
            ostring _name;
            unsigned int _mode;
        };

       /**
        * @brief Internal usage.
        * Class implementing bind translations between C++ vectors and C API arrays
        */ 
        class BindArray : public BindObject
        {
        public:

            BindArray(const ocilib::Statement& statement, const ostring& name, unsigned int mode);
            virtual ~BindArray() noexcept;

            template<class T>
            void SetVector(std::vector<T>& vector, bool isPlSqlTable, unsigned int elemSize);

            template<class T>
            typename BindResolver<T>::OutputType* GetData() const;

            void SetInData() override;
            void SetOutData() override;

            unsigned int GetSize() const;
            unsigned int GetSizeForBindCall() const;

        private:
                typedef std::vector<ObjectType> ObjectVector;
                typedef typename BindResolver<ObjectType>::OutputType NativeType;

                BindArrayObject(const Statement& statement, const ostring& name, ObjectVector& vector, bool isPlSqlTable, unsigned int mode, unsigned int elemSize);
                virtual ~BindArrayObject() noexcept;
                void SetInData() override;
                void SetOutData() override;
                virtual ostring GetName() const = 0;
                virtual bool IsHandleObject() const = 0;
                virtual unsigned int GetSize() const = 0;
                virtual unsigned int GetSizeForBindCall() const = 0;
            };

            template<class T>
            class BindArrayObject : public  AbstractBindArrayObject
            {
            public:
                void AllocData();
                void FreeData() const;

                const Statement& _statement;
                ostring _name;
                ObjectVector& _vector;
                NativeType* _data;
                void SetInData() override;
                void SetOutData() override;
                ostring GetName()const  override;
                bool IsHandleObject() const override;
                unsigned int GetSize() const override;
                unsigned int GetSizeForBindCall() const override;

                operator ObjectVector& () const;
                operator NativeType* () const;
        template<class T>
        class BindObjectAdaptor : public BindObject
        {
            friend class Statement;

        public:

                ostring _name;
                ObjectVector& _vector;
                NativeType* _data;
                bool _isPlSqlTable;
                unsigned int _mode;
            void SetInData() override;
            void SetOutData() override;

            BindObjectAdaptor(const Statement& statement, const ostring& name, unsigned int mode, ObjectType& object, unsigned int size);
            virtual ~BindObjectAdaptor() noexcept;

        private:
       /**
        * @brief Internal usage.
        * Class implementing bind adapters between C++ class and C API types
        */ 
        template<class T>
        class BindObjectAdaptor : public BindObject
        template<class T>
        class BindTypeAdaptor : public BindObject
        {
            friend class Statement;

        public:


            operator NativeType* ()  const;

            void SetInData() override;
            void SetOutData() override;

            BindObjectAdaptor(const ocilib::Statement& statement, const ostring& name, unsigned int mode, ObjectType& object, unsigned int size);
            virtual ~BindObjectAdaptor() noexcept;

        private:

            ObjectType& _object;
            NativeType* _data;
            unsigned int   _size;
        };
        
       /**
        * @brief Internal usage.
        {
        public:

            BindsHolder(const Statement& statement);
            ~BindsHolder() noexcept;

            void Clear();
        public:

            typedef T ObjectType;
            typedef typename BindResolver<ObjectType>::OutputType NativeType;

            operator NativeType* ()  const;
        private:

            std::vector<BindObject*> _bindObjects;
            const Statement& _statement;
        };
    }
}
        private:

            ObjectType& _object;
            NativeType* _data;
        };

       /**
        * @brief Internal usage.
        * Class owning bind objects allowing to set/get C data prior/after a statement execution
        */ 
        class BindsHolder
        {
        public:

            BindsHolder(const ocilib::Statement& statement);
            ~BindsHolder() noexcept;

            void Clear();

            void AddBindObject(BindObject* bindObject);

            void SetOutData();
            void SetInData();

        private:

            std::vector<BindObject*> _bindObjects;
            const ocilib::Statement& _statement;
        };
    }
}

<MSG> added namepace qualification when referencing librry types from the ocilib::support namespace

<DFF> @@ -37,13 +37,13 @@ namespace ocilib
         {
         public:
 
-            BindObject(const Statement& statement, const ostring& name, unsigned int mode);
+            BindObject(const ocilib::Statement& statement, const ostring& name, unsigned int mode);
 
             virtual ~BindObject() noexcept;
 
             ostring GetName() const;
 
-            Statement GetStatement() const;
+            ocilib::Statement GetStatement() const;
 
             unsigned int GetMode() const;
 
@@ -52,7 +52,7 @@ namespace ocilib
 
         protected:
 
-            const Statement& _statement;
+            const ocilib::Statement& _statement;
             ostring _name;
             unsigned int _mode;
         };
@@ -61,7 +61,7 @@ namespace ocilib
         {
         public:
 
-            BindArray(const Statement& statement, const ostring& name, unsigned int mode);
+            BindArray(const ocilib::Statement& statement, const ostring& name, unsigned int mode);
             virtual ~BindArray() noexcept;
 
             template<class T>
@@ -99,7 +99,7 @@ namespace ocilib
                 typedef std::vector<ObjectType> ObjectVector;
                 typedef typename BindResolver<ObjectType>::OutputType NativeType;
 
-                BindArrayObject(const Statement& statement, const ostring& name, ObjectVector& vector, bool isPlSqlTable, unsigned int mode, unsigned int elemSize);
+                BindArrayObject(const ocilib::Statement& statement, const ostring& name, ObjectVector& vector, bool isPlSqlTable, unsigned int mode, unsigned int elemSize);
                 virtual ~BindArrayObject() noexcept;
                 void SetInData() override;
                 void SetOutData() override;
@@ -116,7 +116,7 @@ namespace ocilib
                 void AllocData();
                 void FreeData() const;
 
-                const Statement& _statement;
+                const ocilib::Statement& _statement;
                 ostring _name;
                 ObjectVector& _vector;
                 NativeType* _data;
@@ -132,7 +132,7 @@ namespace ocilib
         template<class T>
         class BindObjectAdaptor : public BindObject
         {
-            friend class Statement;
+            friend class ocilib::Statement;
 
         public:
 
@@ -144,7 +144,7 @@ namespace ocilib
             void SetInData() override;
             void SetOutData() override;
 
-            BindObjectAdaptor(const Statement& statement, const ostring& name, unsigned int mode, ObjectType& object, unsigned int size);
+            BindObjectAdaptor(const ocilib::Statement& statement, const ostring& name, unsigned int mode, ObjectType& object, unsigned int size);
             virtual ~BindObjectAdaptor() noexcept;
 
         private:
@@ -157,7 +157,7 @@ namespace ocilib
         template<class T>
         class BindTypeAdaptor : public BindObject
         {
-            friend class Statement;
+            friend class ocilib::Statement;
 
         public:
 
@@ -182,7 +182,7 @@ namespace ocilib
         {
         public:
 
-            BindsHolder(const Statement& statement);
+            BindsHolder(const ocilib::Statement& statement);
             ~BindsHolder() noexcept;
 
             void Clear();
@@ -195,7 +195,7 @@ namespace ocilib
         private:
 
             std::vector<BindObject*> _bindObjects;
-            const Statement& _statement;
+            const ocilib::Statement& _statement;
         };
     }
 }

{'commit': 'diff --git a/include/ocilibcpp/detail/support/BindArray.hpp b/include/ocilibcpp/detail/support/BindArray.hpp\nindex 84586247..625cbd99 100644\n--- a/include/ocilibcpp/detail/support/BindArray.hpp\n+++ b/include/ocilibcpp/detail/support/BindArray.hpp\n@@ -28,7 +28,7 @@ namespace ocilib\n {\n     namespace support\n     {\n-        inline BindArray::BindArray(const Statement& statement, const ostring& name, unsigned int mode) : BindObject(statement, name, mode), _object(nullptr)\n+        inline BindArray::BindArray(const ocilib::Statement& statement, const ostring& name, unsigned int mode) : BindObject(statement, name, mode), _object(nullptr)\n         {\n \n         }\n@@ -79,7 +79,7 @@ namespace ocilib\n \n \n         template<class T>\n-        BindArray::BindArrayObject<T>::BindArrayObject(const Statement& statement, const ostring& name, ObjectVector& vector, bool isPlSqlTable, unsigned int mode, unsigned int elemSize)\n+        BindArray::BindArrayObject<T>::BindArrayObject(const ocilib::Statement& statement, const ostring& name, ObjectVector& vector, bool isPlSqlTable, unsigned int mode, unsigned int elemSize)\n             : _statement(statement), _name(name), _vector(vector), _data(nullptr), _isPlSqlTable(isPlSqlTable), _mode(mode), _elemCount(BindArrayObject<T>::GetSize()), _elemSize(elemSize)\n         {\n             AllocData();\n@@ -100,7 +100,7 @@ namespace ocilib\n         }\n \n         template<>\n-        inline void BindArray::BindArrayObject<ostring>::AllocData()\n+        inline void BindArray::BindArrayObject<ocilib::ostring>::AllocData()\n         {\n             const size_t count = _elemSize * _elemCount;\n \n@@ -110,7 +110,7 @@ namespace ocilib\n         }\n \n         template<>\n-        inline void BindArray::BindArrayObject<Raw> ::AllocData()\n+        inline void BindArray::BindArrayObject<ocilib::Raw> ::AllocData()\n         {\n             const size_t count = _elemSize * _elemCount;\n \n@@ -140,7 +140,7 @@ namespace ocilib\n         }\n \n         template<>\n-        inline void BindArray::BindArrayObject<ostring>::SetInData()\n+        inline void BindArray::BindArrayObject<ocilib::ostring>::SetInData()\n         {\n             std::vector<ostring>::iterator it, it_end;\n \n@@ -156,7 +156,7 @@ namespace ocilib\n         }\n \n         template<>\n-        inline void BindArray::BindArrayObject<Raw>::SetInData()\n+        inline void BindArray::BindArrayObject<ocilib::Raw>::SetInData()\n         {\n             std::vector<Raw>::iterator it, it_end;\n \n@@ -191,7 +191,7 @@ namespace ocilib\n         }\n \n         template<>\n-        inline void BindArray::BindArrayObject<ostring>::SetOutData()\n+        inline void BindArray::BindArrayObject<ocilib::ostring>::SetOutData()\n         {\n             std::vector<ostring>::iterator it, it_end;\n \n@@ -209,7 +209,7 @@ namespace ocilib\n         }\n \n         template<>\n-        inline void BindArray::BindArrayObject<Raw>::SetOutData()\n+        inline void BindArray::BindArrayObject<ocilib::Raw>::SetOutData()\n         {\n             std::vector<Raw>::iterator it, it_end;\n \ndiff --git a/include/ocilibcpp/detail/support/BindObject.hpp b/include/ocilibcpp/detail/support/BindObject.hpp\nindex 5bc04650..717228cc 100644\n--- a/include/ocilibcpp/detail/support/BindObject.hpp\n+++ b/include/ocilibcpp/detail/support/BindObject.hpp\n@@ -28,7 +28,7 @@ namespace ocilib\n {\n     namespace support\n     {\n-        inline BindObject::BindObject(const Statement& statement, const ostring& name, unsigned int mode) : _statement(statement), _name(name), _mode(mode)\n+        inline BindObject::BindObject(const ocilib::Statement& statement, const ostring& name, unsigned int mode) : _statement(statement), _name(name), _mode(mode)\n         {\n         }\n \n@@ -41,7 +41,7 @@ namespace ocilib\n             return _name;\n         }\n \n-        inline Statement BindObject::GetStatement() const\n+        inline ocilib::Statement BindObject::GetStatement() const\n         {\n             return _statement;\n         }\ndiff --git a/include/ocilibcpp/detail/support/BindObjectAdaptor.hpp b/include/ocilibcpp/detail/support/BindObjectAdaptor.hpp\nindex 5f251c10..014b0e6a 100644\n--- a/include/ocilibcpp/detail/support/BindObjectAdaptor.hpp\n+++ b/include/ocilibcpp/detail/support/BindObjectAdaptor.hpp\n@@ -60,7 +60,7 @@ namespace ocilib\n         }\n \n         template<class T>\n-        BindObjectAdaptor<T>::BindObjectAdaptor(const Statement& statement, const ostring& name, unsigned int mode, ObjectType& object, unsigned int size) :\n+        BindObjectAdaptor<T>::BindObjectAdaptor(const ocilib::Statement& statement, const ostring& name, unsigned int mode, ObjectType& object, unsigned int size) :\n             BindObject(statement, name, mode),\n             _object(object),\n             _data(core::OnAllocate(new NativeType[size + 1], size + 1)),\ndiff --git a/include/ocilibcpp/detail/support/BindResolver.hpp b/include/ocilibcpp/detail/support/BindResolver.hpp\nindex b9493916..5a74be4e 100644\n--- a/include/ocilibcpp/detail/support/BindResolver.hpp\n+++ b/include/ocilibcpp/detail/support/BindResolver.hpp\n@@ -64,20 +64,20 @@ namespace ocilib\n         template<> struct BindResolver<big_uint> : BindResolverScalarType<big_uint> {};\n         template<> struct BindResolver<float> : BindResolverScalarType<float> {};\n         template<> struct BindResolver<double> : BindResolverScalarType<double> {};\n-        template<> struct BindResolver<ostring> : BindResolverType<ostring, otext, false> {};\n-        template<> struct BindResolver<Raw> : BindResolverType<ostring, unsigned char, false> {};\n-        template<> struct BindResolver<Number> : BindResolverHandleType<Number, OCI_Number*> {};\n-        template<> struct BindResolver<Date> : BindResolverHandleType<Date, OCI_Date*> {};\n-        template<> struct BindResolver<Timestamp> : BindResolverHandleType<Timestamp, OCI_Timestamp*> {};\n-        template<> struct BindResolver<Interval> : BindResolverHandleType<Interval, OCI_Interval*> {};\n-        template<> struct BindResolver<Clob> : BindResolverHandleType<Clob, OCI_Lob*> {};\n-        template<> struct BindResolver<NClob> : BindResolverHandleType<NClob, OCI_Lob*> {};\n-        template<> struct BindResolver<Blob> : BindResolverHandleType<Blob, OCI_Lob*> {};\n-        template<> struct BindResolver<File> : BindResolverHandleType<File, OCI_File*> {};\n-        template<> struct BindResolver<Clong> : BindResolverHandleType<Clong, OCI_Long*> {};\n-        template<> struct BindResolver<Blong> : BindResolverHandleType<Blong, OCI_Long*> {};\n-        template<> struct BindResolver<Reference> : BindResolverHandleType<Reference, OCI_Ref*> {};\n-        template<> struct BindResolver<Object> : BindResolverHandleType<Object, OCI_Object*> {};\n-        template<> struct BindResolver<Statement> : BindResolverHandleType<Statement, OCI_Statement*> {};\n+        template<> struct BindResolver<ocilib::ostring> : BindResolverType<ocilib::ostring, otext, false> {};\n+        template<> struct BindResolver<ocilib::Raw> : BindResolverType<ocilib::ostring, unsigned char, false> {};\n+        template<> struct BindResolver<ocilib::Number> : BindResolverHandleType<ocilib::Number, OCI_Number*> {};\n+        template<> struct BindResolver<ocilib::Date> : BindResolverHandleType<ocilib::Date, OCI_Date*> {};\n+        template<> struct BindResolver<ocilib::Timestamp> : BindResolverHandleType<ocilib::Timestamp, OCI_Timestamp*> {};\n+        template<> struct BindResolver<ocilib::Interval> : BindResolverHandleType<ocilib::Interval, OCI_Interval*> {};\n+        template<> struct BindResolver<ocilib::Clob> : BindResolverHandleType<ocilib::Clob, OCI_Lob*> {};\n+        template<> struct BindResolver<ocilib::NClob> : BindResolverHandleType<ocilib::NClob, OCI_Lob*> {};\n+        template<> struct BindResolver<ocilib::Blob> : BindResolverHandleType<ocilib::Blob, OCI_Lob*> {};\n+        template<> struct BindResolver<ocilib::File> : BindResolverHandleType<ocilib::File, OCI_File*> {};\n+        template<> struct BindResolver<ocilib::Clong> : BindResolverHandleType<ocilib::Clong, OCI_Long*> {};\n+        template<> struct BindResolver<ocilib::Blong> : BindResolverHandleType<ocilib::Blong, OCI_Long*> {};\n+        template<> struct BindResolver<ocilib::Reference> : BindResolverHandleType<ocilib::Reference, OCI_Ref*> {};\n+        template<> struct BindResolver<ocilib::Object> : BindResolverHandleType<ocilib::Object, OCI_Object*> {};\n+        template<> struct BindResolver<ocilib::Statement> : BindResolverHandleType<ocilib::Statement, OCI_Statement*> {};\n     }\n }\ndiff --git a/include/ocilibcpp/detail/support/BindTypeAdaptor.hpp b/include/ocilibcpp/detail/support/BindTypeAdaptor.hpp\nindex 9b0cd07a..6cdb5af7 100644\n--- a/include/ocilibcpp/detail/support/BindTypeAdaptor.hpp\n+++ b/include/ocilibcpp/detail/support/BindTypeAdaptor.hpp\n@@ -45,7 +45,7 @@ namespace ocilib\n         }\n \n         template<class T>\n-        BindTypeAdaptor<T>::BindTypeAdaptor(const Statement& statement, const ostring& name, unsigned int mode, ObjectType& object) :\n+        BindTypeAdaptor<T>::BindTypeAdaptor(const ocilib::Statement& statement, const ostring& name, unsigned int mode, ObjectType& object) :\n             BindObject(statement, name, mode),\n             _object(object),\n             _data(core::OnAllocate(new NativeType))\ndiff --git a/include/ocilibcpp/detail/support/BindsHolder.hpp b/include/ocilibcpp/detail/support/BindsHolder.hpp\nindex 0f4626fa..86bbbd38 100644\n--- a/include/ocilibcpp/detail/support/BindsHolder.hpp\n+++ b/include/ocilibcpp/detail/support/BindsHolder.hpp\n@@ -26,7 +26,7 @@ namespace ocilib\n {\n     namespace support\n     {\n-        inline BindsHolder::BindsHolder(const Statement& statement) : _statement(statement)\n+        inline BindsHolder::BindsHolder(const ocilib::Statement& statement) : _statement(statement)\n         {\n \n         }\ndiff --git a/include/ocilibcpp/support.hpp b/include/ocilibcpp/support.hpp\nindex 68923fcc..6840a787 100644\n--- a/include/ocilibcpp/support.hpp\n+++ b/include/ocilibcpp/support.hpp\n@@ -37,13 +37,13 @@ namespace ocilib\n         {\n         public:\n \n-            BindObject(const Statement& statement, const ostring& name, unsigned int mode);\n+            BindObject(const ocilib::Statement& statement, const ostring& name, unsigned int mode);\n \n             virtual ~BindObject() noexcept;\n \n             ostring GetName() const;\n \n-            Statement GetStatement() const;\n+            ocilib::Statement GetStatement() const;\n \n             unsigned int GetMode() const;\n \n@@ -52,7 +52,7 @@ namespace ocilib\n \n         protected:\n \n-            const Statement& _statement;\n+            const ocilib::Statement& _statement;\n             ostring _name;\n             unsigned int _mode;\n         };\n@@ -61,7 +61,7 @@ namespace ocilib\n         {\n         public:\n \n-            BindArray(const Statement& statement, const ostring& name, unsigned int mode);\n+            BindArray(const ocilib::Statement& statement, const ostring& name, unsigned int mode);\n             virtual ~BindArray() noexcept;\n \n             template<class T>\n@@ -99,7 +99,7 @@ namespace ocilib\n                 typedef std::vector<ObjectType> ObjectVector;\n                 typedef typename BindResolver<ObjectType>::OutputType NativeType;\n \n-                BindArrayObject(const Statement& statement, const ostring& name, ObjectVector& vector, bool isPlSqlTable, unsigned int mode, unsigned int elemSize);\n+                BindArrayObject(const ocilib::Statement& statement, const ostring& name, ObjectVector& vector, bool isPlSqlTable, unsigned int mode, unsigned int elemSize);\n                 virtual ~BindArrayObject() noexcept;\n                 void SetInData() override;\n                 void SetOutData() override;\n@@ -116,7 +116,7 @@ namespace ocilib\n                 void AllocData();\n                 void FreeData() const;\n \n-                const Statement& _statement;\n+                const ocilib::Statement& _statement;\n                 ostring _name;\n                 ObjectVector& _vector;\n                 NativeType* _data;\n@@ -132,7 +132,7 @@ namespace ocilib\n         template<class T>\n         class BindObjectAdaptor : public BindObject\n         {\n-            friend class Statement;\n+            friend class ocilib::Statement;\n \n         public:\n \n@@ -144,7 +144,7 @@ namespace ocilib\n             void SetInData() override;\n             void SetOutData() override;\n \n-            BindObjectAdaptor(const Statement& statement, const ostring& name, unsigned int mode, ObjectType& object, unsigned int size);\n+            BindObjectAdaptor(const ocilib::Statement& statement, const ostring& name, unsigned int mode, ObjectType& object, unsigned int size);\n             virtual ~BindObjectAdaptor() noexcept;\n \n         private:\n@@ -157,7 +157,7 @@ namespace ocilib\n         template<class T>\n         class BindTypeAdaptor : public BindObject\n         {\n-            friend class Statement;\n+            friend class ocilib::Statement;\n \n         public:\n \n@@ -182,7 +182,7 @@ namespace ocilib\n         {\n         public:\n \n-            BindsHolder(const Statement& statement);\n+            BindsHolder(const ocilib::Statement& statement);\n             ~BindsHolder() noexcept;\n \n             void Clear();\n@@ -195,7 +195,7 @@ namespace ocilib\n         private:\n \n             std::vector<BindObject*> _bindObjects;\n-            const Statement& _statement;\n+            const ocilib::Statement& _statement;\n         };\n     }\n }\n', 'commit_subject': 'added namepace qualification when referencing librry types from the ocilib::support namespace', 'repo_name': 'vrogier/ocilib', 'committer': {'name': 'Vincent Rogier', 'email': 'ff0016bbe7d0496b299ebd6defbf905adcb5a5d9@gmail.com', 'time_sec': '1589129919', 'tz_offset': '120', 'date': {'seconds': '1589129919'}}, 'commit_tree': '604722c888560a56f9b7e46ebea74bb61064db49', 'commit_message': 'added namepace qualification when referencing librry types from the ocilib::support namespace\n', 'language_name': 'HTML', 'license': 'apache-2.0', 'hunks': '@@ -37,13 +37,13 @@ namespace ocilib\n         {\n         public:\n \n-            BindObject(const Statement& statement, const ostring& name, unsigned int mode);\n+            BindObject(const ocilib::Statement& statement, const ostring& name, unsigned int mode);\n \n             virtual ~BindObject() noexcept;\n \n             ostring GetName() const;\n \n-            Statement GetStatement() const;\n+            ocilib::Statement GetStatement() const;\n \n             unsigned int GetMode() const;\n \n@@ -52,7 +52,7 @@ namespace ocilib\n \n         protected:\n \n-            const Statement& _statement;\n+            const ocilib::Statement& _statement;\n             ostring _name;\n             unsigned int _mode;\n         };\n@@ -61,7 +61,7 @@ namespace ocilib\n         {\n         public:\n \n-            BindArray(const Statement& statement, const ostring& name, unsigned int mode);\n+            BindArray(const ocilib::Statement& statement, const ostring& name, unsigned int mode);\n             virtual ~BindArray() noexcept;\n \n             template<class T>\n@@ -99,7 +99,7 @@ namespace ocilib\n                 typedef std::vector<ObjectType> ObjectVector;\n                 typedef typename BindResolver<ObjectType>::OutputType NativeType;\n \n-                BindArrayObject(const Statement& statement, const ostring& name, ObjectVector& vector, bool isPlSqlTable, unsigned int mode, unsigned int elemSize);\n+                BindArrayObject(const ocilib::Statement& statement, const ostring& name, ObjectVector& vector, bool isPlSqlTable, unsigned int mode, unsigned int elemSize);\n                 virtual ~BindArrayObject() noexcept;\n                 void SetInData() override;\n                 void SetOutData() override;\n@@ -116,7 +116,7 @@ namespace ocilib\n                 void AllocData();\n                 void FreeData() const;\n \n-                const Statement& _statement;\n+                const ocilib::Statement& _statement;\n                 ostring _name;\n                 ObjectVector& _vector;\n                 NativeType* _data;\n@@ -132,7 +132,7 @@ namespace ocilib\n         template<class T>\n         class BindObjectAdaptor : public BindObject\n         {\n-            friend class Statement;\n+            friend class ocilib::Statement;\n \n         public:\n \n@@ -144,7 +144,7 @@ namespace ocilib\n             void SetInData() override;\n             void SetOutData() override;\n \n-            BindObjectAdaptor(const Statement& statement, const ostring& name, unsigned int mode, ObjectType& object, unsigned int size);\n+            BindObjectAdaptor(const ocilib::Statement& statement, const ostring& name, unsigned int mode, ObjectType& object, unsigned int size);\n             virtual ~BindObjectAdaptor() noexcept;\n \n         private:\n@@ -157,7 +157,7 @@ namespace ocilib\n         template<class T>\n         class BindTypeAdaptor : public BindObject\n         {\n-            friend class Statement;\n+            friend class ocilib::Statement;\n \n         public:\n \n@@ -182,7 +182,7 @@ namespace ocilib\n         {\n         public:\n \n-            BindsHolder(const Statement& statement);\n+            BindsHolder(const ocilib::Statement& statement);\n             ~BindsHolder() noexcept;\n \n             void Clear();\n@@ -195,7 +195,7 @@ namespace ocilib\n         private:\n \n             std::vector<BindObject*> _bindObjects;\n-            const Statement& _statement;\n+            const ocilib::Statement& _statement;\n         };\n     }\n }\n', 'addition_count': 11, 'deletion_count': 11, 'src_file': 'a/include/ocilibcpp/support.hpp', 'tgt_file': 'b/include/ocilibcpp/support.hpp', 'file_extension': '.hpp', 'before_file': '/*\n * OCILIB - C Driver for Oracle (C Wrapper for Oracle OCI)\n *\n * Website: http://www.ocilib.net\n *\n * Copyright (c) 2007-2021 Vincent ROGIER <vince.rogier@ocilib.net>\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n *      http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n#pragma once\n\n#include "ocilibcpp/core.hpp"\n\n// ReSharper disable CppClangTidyModernizeUseNodiscard\n// ReSharper disable CppClangTidyHicppUseEqualsDefault\n// ReSharper disable CppClangTidyHicppSpecialMemberFunctions\n// ReSharper disable CppClangTidyCppcoreguidelinesSpecialMemberFunctions\n// ReSharper disable CppClangTidyModernizePassByValue\n\nnamespace ocilib\n{\n    /**\n     * @namespace ocilib::support\n     * @brief OCILIB internal support classes \n     *\n        {\n        public:\n\n            BindObject(const Statement& statement, const ostring& name, unsigned int mode);\n\n            virtual ~BindObject() noexcept;\n\n            ostring GetName() const;\n\n            Statement GetStatement() const;\n\n            unsigned int GetMode() const;\n\n        */ \n        class BindObject\n\n        protected:\n\n            const Statement& _statement;\n            ostring _name;\n            unsigned int _mode;\n        };\n            ostring GetName() const;\n\n        {\n        public:\n\n            BindArray(const Statement& statement, const ostring& name, unsigned int mode);\n            virtual ~BindArray() noexcept;\n\n            template<class T>\n        protected:\n\n            const ocilib::Statement& _statement;\n            ostring _name;\n            unsigned int _mode;\n        };\n\n       /**\n        * @brief Internal usage.\n        * Class implementing bind translations between C++ vectors and C API arrays\n        */ \n        class BindArray : public BindObject\n        {\n        public:\n\n            BindArray(const ocilib::Statement& statement, const ostring& name, unsigned int mode);\n            virtual ~BindArray() noexcept;\n\n            template<class T>\n            void SetVector(std::vector<T>& vector, bool isPlSqlTable, unsigned int elemSize);\n\n            template<class T>\n            typename BindResolver<T>::OutputType* GetData() const;\n\n            void SetInData() override;\n            void SetOutData() override;\n\n            unsigned int GetSize() const;\n            unsigned int GetSizeForBindCall() const;\n\n        private:\n                typedef std::vector<ObjectType> ObjectVector;\n                typedef typename BindResolver<ObjectType>::OutputType NativeType;\n\n                BindArrayObject(const Statement& statement, const ostring& name, ObjectVector& vector, bool isPlSqlTable, unsigned int mode, unsigned int elemSize);\n                virtual ~BindArrayObject() noexcept;\n                void SetInData() override;\n                void SetOutData() override;\n                virtual ostring GetName() const = 0;\n                virtual bool IsHandleObject() const = 0;\n                virtual unsigned int GetSize() const = 0;\n                virtual unsigned int GetSizeForBindCall() const = 0;\n            };\n\n            template<class T>\n            class BindArrayObject : public  AbstractBindArrayObject\n            {\n            public:\n                void AllocData();\n                void FreeData() const;\n\n                const Statement& _statement;\n                ostring _name;\n                ObjectVector& _vector;\n                NativeType* _data;\n                void SetInData() override;\n                void SetOutData() override;\n                ostring GetName()const  override;\n                bool IsHandleObject() const override;\n                unsigned int GetSize() const override;\n                unsigned int GetSizeForBindCall() const override;\n\n                operator ObjectVector& () const;\n                operator NativeType* () const;\n        template<class T>\n        class BindObjectAdaptor : public BindObject\n        {\n            friend class Statement;\n\n        public:\n\n                ostring _name;\n                ObjectVector& _vector;\n                NativeType* _data;\n                bool _isPlSqlTable;\n                unsigned int _mode;\n            void SetInData() override;\n            void SetOutData() override;\n\n            BindObjectAdaptor(const Statement& statement, const ostring& name, unsigned int mode, ObjectType& object, unsigned int size);\n            virtual ~BindObjectAdaptor() noexcept;\n\n        private:\n       /**\n        * @brief Internal usage.\n        * Class implementing bind adapters between C++ class and C API types\n        */ \n        template<class T>\n        class BindObjectAdaptor : public BindObject\n        template<class T>\n        class BindTypeAdaptor : public BindObject\n        {\n            friend class Statement;\n\n        public:\n\n\n            operator NativeType* ()  const;\n\n            void SetInData() override;\n            void SetOutData() override;\n\n            BindObjectAdaptor(const ocilib::Statement& statement, const ostring& name, unsigned int mode, ObjectType& object, unsigned int size);\n            virtual ~BindObjectAdaptor() noexcept;\n\n        private:\n\n            ObjectType& _object;\n            NativeType* _data;\n            unsigned int   _size;\n        };\n        \n       /**\n        * @brief Internal usage.\n        {\n        public:\n\n            BindsHolder(const Statement& statement);\n            ~BindsHolder() noexcept;\n\n            void Clear();\n        public:\n\n            typedef T ObjectType;\n            typedef typename BindResolver<ObjectType>::OutputType NativeType;\n\n            operator NativeType* ()  const;\n        private:\n\n            std::vector<BindObject*> _bindObjects;\n            const Statement& _statement;\n        };\n    }\n}\n        private:\n\n            ObjectType& _object;\n            NativeType* _data;\n        };\n\n       /**\n        * @brief Internal usage.\n        * Class owning bind objects allowing to set/get C data prior/after a statement execution\n        */ \n        class BindsHolder\n        {\n        public:\n\n            BindsHolder(const ocilib::Statement& statement);\n            ~BindsHolder() noexcept;\n\n            void Clear();\n\n            void AddBindObject(BindObject* bindObject);\n\n            void SetOutData();\n            void SetInData();\n\n        private:\n\n            std::vector<BindObject*> _bindObjects;\n            const ocilib::Statement& _statement;\n        };\n    }\n}\n', 'message': 'added namepace qualification when referencing librry types from the ocilib::support namespace\n', 'author_name': 'Vincent Rogier', 'lang': 'hpp'}