5 * @author Pradeep Gore <pradeep@oomworks.com>
8 #ifndef TAO_Notify_Tests_DRIVER_H
9 #define TAO_Notify_Tests_DRIVER_H
10 #include /**/ "ace/pre.h"
12 #include "notify_test_export.h"
14 #if !defined (ACE_LACKS_PRAGMA_ONCE)
16 #endif /* ACE_LACKS_PRAGMA_ONCE */
18 #include "ace/Service_Config.h"
23 #include "Driver_Base.h"
25 class TAO_Notify_Tests_Command_Builder
;
26 class TAO_Notify_Tests_Activation_Manager
;
29 * @class TAO_Notify_Tests_Worker
31 * @brief A Task to execute commands asynchronously.
33 class TAO_Notify_Tests_Worker
: public ACE_Task_Base
36 TAO_Notify_Tests_Worker ();
39 /// Set the command builder.
40 void command_builder (TAO_Notify_Tests_Command_Builder
* cmd_builder
);
43 // The thread entry point.
48 /// The command builder
49 TAO_Notify_Tests_Command_Builder
* cmd_builder_
;
56 * Use the ACE_Task_Base class to run server threads
58 class TAO_Notify_Tests_ORB_Run_Worker
: public ACE_Task_Base
61 TAO_Notify_Tests_ORB_Run_Worker ();
64 void orb (CORBA::ORB_ptr orb
);
66 /// Srt the run period.
67 void run_period (ACE_Time_Value run_period
);
70 // The thread entry point.
77 ACE_Time_Value run_period_
;
82 * @class TAO_Notify_Tests_Driver
84 * @brief A default Application Starter.
86 class TAO_NOTIFY_TEST_Export TAO_Notify_Tests_Driver
: public TAO_Notify_Tests_Driver_Base
90 TAO_Notify_Tests_Driver ();
93 ~TAO_Notify_Tests_Driver ();
96 int init (int argc
, ACE_TCHAR
*argv
[]);
98 /// Execute the commands.
102 virtual void shutdown ();
105 /// Parse command line parameters.
106 int parse_args (int argc
, ACE_TCHAR
*argv
[]);
108 /// The command builder
109 TAO_Notify_Tests_Command_Builder
* cmd_builder_
;
111 /// Manage activation of periodic suppliers and consumers.
112 TAO_Notify_Tests_Activation_Manager
* activation_manager_
;
114 /// Thread in which to run commands.
115 TAO_Notify_Tests_Worker worker_
;
117 /// Thread in which to run the orb.
118 TAO_Notify_Tests_ORB_Run_Worker orb_run_worker_
;
124 ACE_Time_Value run_period_
;
126 /// The file for output
127 ACE_CString ior_output_file_
;
129 /// The file for input
130 ACE_CString ior_input_file_
;
132 /// Set to skip the check for multiple priority levels.
133 int skip_priority_levels_check_
;
136 #include /**/ "ace/post.h"
137 #endif /* TAO_Notify_Tests_DRIVER_H */