Merge pull request #1844 from jrw972/monterey
[ACE_TAO.git] / TAO / tests / Bug_1383_Regression / simple_i.cpp
blobf6a94dabbc0845d18ab32e93180a2e934b34057f
1 #include "simple_i.h"
2 #include "tao/ORB_Core.h"
3 #include "ace/Reactor.h"
5 Simple_i::Simple_i(CORBA::ORB_ptr orb)
6 : m_orb(orb->_duplicate(orb))
10 void Simple_i::registerCallee(Callee_ptr value)
12 ACE_DEBUG ((LM_DEBUG, "registerCallee invoked\n"));
13 // retain a reference so we can callback later
14 m_callee = value->_duplicate(value);
16 // register a callback with the reactor so we can invoke the
17 // callback method
18 m_orb->orb_core()->reactor()->schedule_timer(this, 0, ACE_Time_Value(5));
21 int Simple_i::handle_timeout(const ACE_Time_Value &,
22 const void *)
24 ACE_DEBUG ((LM_DEBUG, "timer expired\n"));
25 m_callee->callback("got timeout");
26 return 0;