IBase.h
Go to the documentation of this file.
00001 //-----------------------------------------------------------------------------
00002 //  (c) 2006 by Basler Vision Technologies
00003 //  Section: Vision Components
00004 //  Project: GenApi
00005 //  Author:  Fritz Dierks
00006 //  $Header$
00007 //
00008 //  License: This file is published under the license of the EMVA GenICam  Standard Group.
00009 //  A text file describing the legal terms is included in  your installation as 'GenICam_license.pdf'.
00010 //  If for some reason you are missing  this file please contact the EMVA or visit the website
00011 //  (http://www.genicam.org) for a full copy.
00012 //
00013 //  THIS SOFTWARE IS PROVIDED BY THE EMVA GENICAM STANDARD GROUP "AS IS"
00014 //  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
00015 //  THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
00016 //  PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE EMVA GENICAM STANDARD  GROUP
00017 //  OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,  SPECIAL,
00018 //  EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT  LIMITED TO,
00019 //  PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  DATA, OR PROFITS;
00020 //  OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY  THEORY OF LIABILITY,
00021 //  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT  (INCLUDING NEGLIGENCE OR OTHERWISE)
00022 //  ARISING IN ANY WAY OUT OF THE USE  OF THIS SOFTWARE, EVEN IF ADVISED OF THE
00023 //  POSSIBILITY OF SUCH DAMAGE.
00024 //-----------------------------------------------------------------------------
00032 #ifndef GENAPI_IBASE_H
00033 #define GENAPI_IBASE_H
00034 
00035 #include <GenApi/GenApiDll.h>
00036 #include <GenApi/Types.h>
00037 #include <GenApi/Reference.h>
00038 
00039 #ifdef _MSC_VER
00040 #   pragma warning ( push )
00041 #   pragma warning ( disable : 4251 ) // XXX needs to have dll-interface to be used by clients of class YYY
00042 #endif
00043 
00044 namespace GENAPI_NAMESPACE
00045 {
00046     //*************************************************************
00047     // IBase interface
00048     //*************************************************************
00049 
00054     interface GENAPI_DECL_ABSTRACT IBase
00055     {
00057         virtual EAccessMode GetAccessMode() const = 0;
00058 
00060     virtual ~IBase() = 0;
00061     };
00062 
00063   // Implementation required for Windows only.
00064   // Note: the C++ standard >= 11 prohibit pure virtual destructors with a function body
00065   // in the declaration. Consequently gcc 4.0 and newer reject an inline implementation
00066   // in the class.
00067   inline IBase::~IBase()
00068   {
00069     // do nothing
00070   }
00071 
00072     //*************************************************************
00073     // CBaseRef class
00074     //*************************************************************
00075 
00076 #ifndef DOXYGEN_IGNORE
00077 
00083     template <class T, class I=T>
00084     class CBaseRefT : public CReferenceT<T, I>
00085     {
00086         typedef CReferenceT<T, I> ref;
00087 
00088     public:
00089         /*--------------------------------------------------------*/
00090         // IBase
00091         /*--------------------------------------------------------*/
00092 
00094         virtual EAccessMode GetAccessMode() const
00095         {
00096             if(ref::m_Ptr)
00097                 return ref::m_Ptr->GetAccessMode();
00098             else
00099                 return NI;
00100         }
00101 
00102     };
00103 
00106     typedef CBaseRefT<IBase> CBaseRef;
00107 
00108 #endif
00109 
00110 }
00111 #ifdef _MSC_VER
00112 #   pragma warning ( pop )
00113 #endif
00114 
00115 #endif // ifndef GENAPI_IBASE_H


rc_genicam_api
Author(s): Heiko Hirschmueller
autogenerated on Thu Jun 6 2019 18:42:47