Revert "Use a variable on the stack to not have a temporary in the call"
[ACE_TAO.git] / TAO / tests / NestedUpcall / Triangle_Test / Object_A_i.cpp
blob94d48a82e4b575730ab391dc48b90ba9a00de62b
2 //=============================================================================
3 /**
4 * @file Object_A_i.cpp
6 * This class implements the Object A of the
7 * Nested Upcalls - Triangle test.
9 * @author Michael Kircher
11 //=============================================================================
14 #include "Object_A_i.h"
15 #include "tao/ORB_Core.h"
16 #include "ace/Reactor.h"
18 // CTOR
19 Object_A_i::Object_A_i ()
20 : finish_two_way_call_ (0)
24 // DTOR
25 Object_A_i::~Object_A_i ()
30 void
31 Object_A_i::foo (Initiator_ptr theInitiator_ptr)
33 try
35 theInitiator_ptr->foo_object_B ();
37 while (!this->finish_two_way_call_)
38 TAO_ORB_Core_instance ()->reactor ()->handle_events ();
40 catch (const CORBA::Exception& ex)
42 ex._tao_print_exception ("calling the initiator");
47 void
48 Object_A_i::finish ()
50 this->finish_two_way_call_ = 1;
53 void
54 Object_A_i::shutdown ()
56 int argc = 0;
57 ACE_TCHAR **argv = 0;
58 CORBA::ORB_var orb = CORBA::ORB_init (argc, argv);
60 orb->shutdown ();