Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
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
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