Updated logging to include the class/method so that it is more obvious where these...
[ACE_TAO.git] / TAO / tao / Time_Policy_Manager.h
blobab665a8221ab02ca485c8893597ca4535fc8131c
1 // -*- C++ -*-
3 //=============================================================================
4 /**
5 * @file Time_Policy_Manager.h
7 * @author Martin Corino <mcorino@remedy.nl>
8 */
9 //=============================================================================
11 #ifndef TIME_POLICY_MANAGER_H
12 #define TIME_POLICY_MANAGER_H
14 #include /**/ "ace/pre.h"
16 #include "tao/TAO_Export.h"
18 #if !defined (ACE_LACKS_PRAGMA_ONCE)
19 # pragma once
20 #endif /* ACE_LACKS_PRAGMA_ONCE */
22 #include "tao/orbconf.h"
24 #if (TAO_HAS_TIME_POLICY == 1)
26 #include "tao/Time_Policy_Strategy.h"
28 #include "ace/Service_Object.h"
29 #include "ace/Timer_Queuefwd.h"
30 #include "ace/Time_Policy.h"
31 #include "ace/Service_Config.h"
33 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
35 /**
36 * @class Time_Policy_Manager
38 * @brief Manager service for time policy strategy services.
40 class TAO_Export TAO_Time_Policy_Manager
41 : public ACE_Service_Object
43 public:
44 TAO_Time_Policy_Manager ();
45 virtual ~TAO_Time_Policy_Manager ();
47 // = Service Configurator hooks.
48 /// Dynamic linking hook
49 virtual int init (int argc, ACE_TCHAR* argv[]);
51 /// Parse svc.conf arguments
52 int parse_args (int argc, ACE_TCHAR* argv[]);
54 virtual ACE_Timer_Queue * create_timer_queue (void);
56 virtual void destroy_timer_queue (ACE_Timer_Queue *tmq);
58 private:
59 enum Time_Policy_Setting
61 TAO_OS_TIME_POLICY,
62 TAO_HR_TIME_POLICY,
63 TAO_DYN_TIME_POLICY
66 TAO_SYNCH_MUTEX lock_;
68 TAO_Time_Policy_Strategy * time_policy_strategy_;
70 Time_Policy_Setting time_policy_setting_;
72 ACE_CString time_policy_name_;
75 ACE_STATIC_SVC_DECLARE_EXPORT (TAO, TAO_Time_Policy_Manager)
76 ACE_FACTORY_DECLARE (TAO, TAO_Time_Policy_Manager)
78 TAO_END_VERSIONED_NAMESPACE_DECL
80 #endif /* TAO_HAS_TIME_POLICY */
82 #include /**/ "ace/post.h"
84 #endif /* TIME_POLICY_MANAGER_H */