3 //=============================================================================
7 * @author Iliyan Jeliazkov <iliyan@ociweb.com>
9 //=============================================================================
11 #ifndef SERVICE_CONFIG_ORB_DLL_H
12 #define SERVICE_CONFIG_ORB_DLL_H
14 #include /**/ "ace/pre.h"
16 #include "ORB_DLL_Export.h"
18 #if !defined (ACE_LACKS_PRAGMA_ONCE)
20 #endif /* ACE_LACKS_PRAGMA_ONCE */
25 #include "ace/String_Base.h"
32 Abstract_Worker (const ACE_TCHAR
*ior
);
33 virtual ~Abstract_Worker ();
34 virtual int test_main (int argc
,
35 ACE_TCHAR
*argv
[]) = 0;
36 virtual const ACE_TCHAR
* kind () const = 0;
38 ACE_TString ior_file_
;
42 * A server kind of test
44 class Server_Worker
: public Abstract_Worker
49 int test_main (int argc
, ACE_TCHAR
*argv
[]);
50 const ACE_TCHAR
* kind () const;
53 int parse_args (int argc
, ACE_TCHAR
*argv
[]);
57 * A client kind of test
59 class Client_Worker
: public Abstract_Worker
64 int test_main (int argc
, ACE_TCHAR
*argv
[]);
65 const ACE_TCHAR
* kind () const;
68 int parse_args (int argc
, ACE_TCHAR
*argv
[]);
72 * @class Service_Config_ORB_DLL
74 * @brief The Service_Config_ORB_DLL that is instantiated when the
75 * client-side test module/library is dynamically loaded.
77 class Service_Config_ORB_DLL_Export Service_Config_ORB_DLL
78 : public ACE_Task_Base
82 Service_Config_ORB_DLL ();
83 ~Service_Config_ORB_DLL ();
85 /// Initializes object when dynamic linking occurs.
86 virtual int init (int argc
, ACE_TCHAR
*argv
[]);
88 /// Run by a daemon thread.
90 * Each thread will invoke the Service Configurator via this
91 * method unless the object is the "FINAL" object.
96 signed char is_server_
;
97 std::unique_ptr
<Abstract_Worker
> worker_
;
98 std::unique_ptr
<ACE_ARGV
> argv_
;
101 ACE_FACTORY_DECLARE (Service_Config_ORB_DLL
, Service_Config_ORB_DLL
)
103 #include /**/ "ace/post.h"
105 #endif /* SERVICE_CONFIG_ORB_DLL_H */