00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015 #ifndef Locator_NT_Service_H
00016 #define Locator_NT_Service_H
00017
00018 #include "ace/config-all.h"
00019
00020 #if defined (ACE_WIN32) && !defined (ACE_LACKS_WIN32_SERVICES)
00021
00022 #include "ace/NT_Service.h"
00023 #include "ace/Singleton.h"
00024 #include "ace/Synch.h"
00025 #include "tao/orbconf.h"
00026
00027 static const char * IMR_LOCATOR_SERVICE_NAME = "TAOImR";
00028 static const char * IMR_LOCATOR_DISPLAY_NAME = "TAO Implementation Repository";
00029 static const char * IMR_LOCATOR_DESCRIPTION = "Implementation Repository Locator service for TAO";
00030
00031
00032
00033
00034
00035
00036 class Locator_NT_Service : public ACE_NT_Service
00037 {
00038 public:
00039 typedef TAO_SYNCH_RECURSIVE_MUTEX MUTEX;
00040
00041
00042
00043 virtual void handle_control (DWORD control_code);
00044
00045
00046
00047 virtual int handle_exception (ACE_HANDLE h);
00048
00049
00050 virtual int svc (void);
00051
00052 private:
00053 friend class ACE_Singleton<Locator_NT_Service, MUTEX>;
00054 };
00055
00056 typedef ACE_Singleton<Locator_NT_Service, ACE_Mutex> SERVICE;
00057
00058 #endif
00059
00060 #endif