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
00032 #ifndef GENAPI_IEEE1212PARSER_H
00033 #define GENAPI_IEEE1212PARSER_H
00034
00035 #include <map>
00036 #include "../Types.h"
00037 #include "Register.h"
00038
00039 #ifdef _MSC_VER // *JS*
00040 #pragma warning(push)
00041 #pragma warning(disable: 4251) // class 'xxx' needs to have dll-interface to be used by clients of class 'yyy'
00042 #endif
00043
00044 namespace GENAPI_NAMESPACE
00045 {
00046
00063 class CIEEE1212ParserImpl : public CRegisterImpl
00064 {
00065 public:
00066 CIEEE1212ParserImpl(void);
00067 ~CIEEE1212ParserImpl(void);
00068
00069 void FinalConstruct();
00070
00071 protected:
00072
00074 virtual EInterfaceType InternalGetPrincipalInterfaceType() const
00075 {
00076 return intfIRegister;
00077 }
00078
00079
00080
00081
00082
00084 virtual GENICAM_NAMESPACE::gcstring InternalToString(bool Verify = false, bool IgnoreCache = false);
00085
00086
00087
00088
00090
00091 virtual void SetProperty(CProperty &Property);
00092 virtual bool GetProperty(CNodeDataMap *pNodeDataMap, CPropertyID::EProperty_ID_t PropertyID, CNodeData::PropertyVector_t &PropertyList) const;
00093 virtual void SetInvalid(INodePrivate::ESetInvalidMode simMode);
00094
00095
00096 virtual bool IsTerminalNode() const;
00097
00098
00099 public:
00100
00101
00102
00103 bool GetValue( uint8_t Key, uint64_t& Value );
00104 bool GetDescriptor( uint8_t Key, GENICAM_NAMESPACE::gcstring& Value );
00105
00107 uint8_t* GetBuffer();
00108
00109
00110
00111
00112 public:
00113 typedef uint8_t Key_t;
00114 private:
00115
00116 typedef std::map< Key_t, uint32_t > ValueMap_t;
00118 typedef std::map< Key_t, GENICAM_NAMESPACE::gcstring > DescriptorMap_t;
00119
00120 protected:
00121 virtual void InternalGet(uint8_t *, int64_t, bool Verify = false, bool IgnoreCache = false );
00122 private:
00123 bool CheckAddressRange( void *pv ) const;
00124 bool CheckIdentity() const;
00125
00126 bool ParseConfRom( Key_t );
00127 bool ParseDirectory( uint32_t *p, Key_t searchkey, Key_t mapkey );
00128 bool ParseDescriptor( uint32_t *p, Key_t key );
00129 bool ParseRootDirectory( uint32_t *p, Key_t key );
00130 bool ParseUnitDependentDirectory( uint32_t *p, Key_t key );
00131 bool ParseUnitDirectory( uint32_t *p, Key_t key );
00132 static uint64_t UnitIdentifier( const uint32_t BusInfo[] );
00133 uint32_t* LocateUnitDirectory( uint32_t *pInstance, Key_t key=0xD1);
00134 bool InsertValues( uint32_t *q, bool lookup , Key_t key );
00135
00136 uint32_t m_UnitId;
00137 uint32_t m_CharSet;
00138 uint32_t m_Language;
00139 uint64_t m_Identity;
00140
00142 uint32_t *m_pUnitDirectory;
00143
00145 ValueMap_t m_ValueMap;
00146
00148 DescriptorMap_t m_DescMap;
00149
00151 uint8_t *m_pBuffer;
00152
00153 };
00154
00155 class CIEEE1212Parser : public BaseT< ValueT< RegisterT< NodeT< CIEEE1212ParserImpl > > > >
00156 {
00157 };
00158
00159 }
00160
00161 #ifdef _MSC_VER // *JS*
00162 #pragma warning(pop)
00163 #endif
00164
00165 #endif // GENAPI_IEEE1212PARSER_H