summaryrefslogtreecommitdiff
path: root/TAO/tests/Two_Objects/First_i.cpp
blob: 6e0c6e2c4651c95bf451cb5d594f068549ad2a60 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
//
// $Id$
//

#include "First_i.h"
#include "tao/ORB_Core.h"
#include "tao/debug.h"
#include "tao/Transport_Cache_Manager.h"
#include "ace/Synch.h"

ACE_RCSID(Test, Test, "$Id$")

First_i::First_i (CORBA::ORB_ptr orb, ACE_Auto_Event &two_way_done)
  : orb_ (CORBA::ORB::_duplicate (orb)),
    two_way_done_(two_way_done)
{
}

void
First_i::oneway_method (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
      ACE_THROW_SPEC ((CORBA::SystemException))
{
  ACE_DEBUG ((LM_DEBUG, "Oneway servant : (%P|%t) one way method called. About to wait for two way call completion\n"));

  two_way_done_.wait ();

  ACE_DEBUG ((LM_DEBUG, "Oneway servant : (%P|%t) woke up after wait\n"));
}