blob: d73f3ab9cb5a8bbe42b5457a9861fe810a44891f (
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
// $Id$
// ===========================================================
//
// = LIBRARY
// TAO/examples/Callback_Quoter
//
// = FILENAME
// Consumer_i.cpp
//
// = DESCRIPTION
// Implements the Consumer_i class, which is used by the
// callback quoter client.
//
// = AUTHOR
// Kirthika Parameswaran <kirthika@cs.wustl.edu>
//
// ===========================================================
#include "Consumer_i.h"
Consumer_i::Consumer_i (void)
{
}
Consumer_i::~Consumer_i (void)
{
}
void
Consumer_i::push (const Callback_Quoter::Info& data,
CORBA::Environment &)
{
// On getting the needed information you now proceed to the next
// step, which could be obtaining the shares.
this->done_ = 1;
ACE_DEBUG ((LM_DEBUG,
"Selling 10,000 %s shares at %d!!\n",
data.stock_name.in (),
data.value));
}
void
Consumer_i::shutdown (CORBA::Environment &)
{
// Instruct the ORB to shutdown.
this->orb_->shutdown ();
}
void
Consumer_i::orb (CORBA::ORB_ptr o)
{
this->orb_ = CORBA::ORB::_duplicate (o);
}
|