Revert "Use a variable on the stack to not have a temporary in the call"
[ACE_TAO.git] / TAO / tests / NestedUpcall / Triangle_Test / initiator.h
blobba7c39fe1a5e6696902e1fee1152927c09517a00
2 //=============================================================================
3 /**
4 * @file initiator.h
6 * This class implements a simple server for the
7 * Nested Upcalls - Triangle test
9 * @author Michael Kircher
11 //=============================================================================
14 #ifndef _TRIANGLE_TEST_INITITATOR_SERVER_H
15 #define _TRIANGLE_TEST_INITITATOR_SERVER_H
17 #include "ace/Get_Opt.h"
19 #if !defined (ACE_LACKS_PRAGMA_ONCE)
20 # pragma once
21 #endif /* ACE_LACKS_PRAGMA_ONCE */
23 #include "ace/Log_Msg.h"
24 #include "tao/Utils/ORB_Manager.h"
25 #include "Initiator_i.h"
27 /**
28 * @class Initiator_Server
30 * @brief This is the server for the Initiator in the test.
32 * See the README file for more information.
34 class Initiator_Server
36 public:
37 /// Default constructor
38 Initiator_Server ();
40 /// Destructor
41 ~Initiator_Server ();
43 /// read in the IOR's for the two objects A and B
44 int read_ior (ACE_TCHAR *filename, unsigned int A_B);
46 /// Initialize the Initiator_Server state - parsing arguments and ...
47 int init (int argc,
48 ACE_TCHAR **argv);
50 /// Run the orb
51 int run ();
53 private:
54 /// Parses the commandline arguments.
55 int parse_args ();
57 /// The IOR of object A
58 char * object_A_key_;
60 /// The IOR of object B
61 char * object_B_key_;
63 /// reference to object A
64 Object_A_var object_A_var_;
66 /// reference to object B
67 Object_B_var object_B_var_;
69 /// The ORB manager
70 TAO_ORB_Manager orb_manager_;
72 /// Implementation object of the Initiator
73 Initiator_i *initiator_i_ptr_;
75 /// Number of commandline arguments.
76 int argc_;
78 /// commandline arguments.
79 ACE_TCHAR **argv_;
81 /// IOR of my servant.
82 CORBA::String_var str_;
85 #endif /* _TRIANGLE_TEST_INITITATOR_SERVER_H */