MeVisLabToolboxReference
|
00001 //----------------------------------------------------------------------------- 00002 // **InsertLicense** code 00003 //----------------------------------------------------------------------------- 00005 00010 //----------------------------------------------------------------------------- 00011 00012 #ifndef CLASS_DCMTREE_UIDGENERATOR 00013 #define CLASS_DCMTREE_UIDGENERATOR 00014 00015 #include <string> 00016 00017 #include "DCMTree_ThreadSupport.h" 00018 00019 #include "DCMTree_Defines.h" 00020 00021 00022 namespace DCMTree_Utils 00023 { 00034 class DCMTREE_EXPORT UIDGenerator 00035 { 00036 public: 00045 static void initialize (std::string iso_root_uid,std::string systemtype,std::string softwaretype, 00046 std::string replacementMac=std::string()); 00047 00051 static std::string uid(); 00052 00056 static bool isInitialized(); 00057 00058 private: 00065 static std::string getMac(); 00066 00070 static unsigned long getProcID(); 00071 00076 static std::string getTimeStr(); 00077 00078 static thread_criticalsection _lock; 00079 static std::string _prefix; 00080 static bool _initialized; 00081 }; 00082 } 00083 00084 #endif 00085 00086