00001 00023 #ifndef __NEW_SIM_ENTITY_H__ 00024 #define __NEW_SIM_ENTITY_H__ 00025 00026 00027 #include <glib.h> 00028 #include <string.h> 00029 00030 00031 extern "C" { 00032 #include "SaHpi.h" 00033 } 00034 00035 #ifndef __NEW_SIM_LOG_h__ 00036 #include "new_sim_log.h" 00037 #endif 00038 00039 00045 class NewSimulatorEntityPath { 00046 public: 00047 SaHpiEntityPathT m_entity_path; 00048 00050 NewSimulatorEntityPath(); 00052 NewSimulatorEntityPath( const SaHpiEntityPathT &entity_path ); 00054 operator SaHpiEntityPathT() { return m_entity_path; } 00055 00056 void SetEntry( int idx, SaHpiEntityTypeT type, SaHpiEntityLocationT instance ); 00057 SaHpiEntityTypeT GetEntryType( int idx ); 00058 void SetEntryType( int idx, SaHpiEntityTypeT type ); 00059 SaHpiEntityLocationT GetEntryInstance( int idx ); 00060 void SetEntryInstance( int idx, SaHpiEntityLocationT instance ); 00061 00062 void AppendRoot( int idx ); 00063 bool FromString( const char *str ); 00064 00065 NewSimulatorEntityPath &operator+=( const NewSimulatorEntityPath &epath ); 00066 bool operator==( const NewSimulatorEntityPath &epath ) const; 00067 bool operator!=( const NewSimulatorEntityPath &epath ) const; 00068 00069 }; 00070 00071 00072 NewSimulatorLog &operator<<( NewSimulatorLog &log, const NewSimulatorEntityPath &epath ); 00073 00074 00075 00076 #endif