BaseT.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:  Alexander Happe
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 //-----------------------------------------------------------------------------
00031 #ifndef GENAPI_BASET_H
00032 #define GENAPI_BASET_H
00033 
00034 #include "../Synch.h"
00035 #include "../IBase.h"
00036 #include "../EnumClasses.h"
00037 #include "GenApi/impl/Log.h"
00038 #include "Exception.h"
00039 
00040 
00041 
00042 namespace GENAPI_NAMESPACE
00043 {
00047     template<class Base>
00048     class BaseT : public Base
00049     {
00050     public:
00052         virtual EAccessMode GetAccessMode() const
00053         {
00054             AutoLock l(Base::GetLock());
00055 
00056             // Use cache
00057             #if ! defined( DISABLE_ACCESS_MODE_CACHING ) || (DISABLE_ACCESS_MODE_CACHING == 0)
00058 #pragma BullseyeCoverage off
00059             if (    _UndefinedAccesMode != Base::m_AccessModeCache
00060                  && _CycleDetectAccesMode != Base::m_AccessModeCache
00061                 )
00062 #pragma BullseyeCoverage on
00063             {
00064                     EAccessMode AccessMode  = Combine(Base::m_AccessModeCache, Base::m_ImposedAccessMode);
00065                     GCLOGINFO( Base::m_pAccessLog, "GetAccessMode = '%s' (from cache)", EAccessModeClass::ToString(AccessMode).c_str() );
00066 
00067                     return AccessMode;
00068                 }
00069 
00070             #endif
00071 
00072             typename Base::EntryMethodFinalizer E( this, meGetAccessMode );
00073         
00074             GCLOGINFOPUSH( Base::m_pAccessLog, "GetAccessMode...");
00075 
00076             EAccessMode NaturalAccessMode = Base::InternalGetAccessMode();
00077 
00078             EAccessMode AccessMode = Combine(NaturalAccessMode, Base::m_ImposedAccessMode);
00079             GCLOGINFOPOP( Base::m_pAccessLog, "...GetAccessMode = '%s' ", EAccessModeClass::ToString(AccessMode).c_str() );
00080 
00081             return AccessMode;
00082 
00083         }
00084 
00085     };
00086 }
00087 
00088 #endif


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