blob: cbe2721a94d02aca2dcc09ce227209128a739a7e (
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
|
// $Id$
#include "Foo_i.h"
#include "TestInf/AppShutdown.h"
#include "ace/OS.h"
#include "ace/Time_Value.h"
Foo_i::Foo_i()
{
for (unsigned i = 0; i < 5; i++)
{
this->op_count_[i] = 0;
}
}
Foo_i::~Foo_i()
{
}
void
Foo_i::op1(ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
ACE_THROW_SPEC((CORBA::SystemException))
{
this->op_count_[0]++;
}
void
Foo_i::op2(CORBA::Long value ACE_ENV_ARG_DECL_NOT_USED)
ACE_THROW_SPEC((CORBA::SystemException))
{
ACE_UNUSED_ARG(value);
this->op_count_[1]++;
}
CORBA::Long
Foo_i::op3(CORBA::Long value ACE_ENV_ARG_DECL_NOT_USED)
ACE_THROW_SPEC((CORBA::SystemException))
{
this->op_count_[2]++;
return value;
}
void
Foo_i::op4(CORBA::Long value ACE_ENV_ARG_DECL_NOT_USED)
ACE_THROW_SPEC((CORBA::SystemException))
{
ACE_UNUSED_ARG(value);
this->op_count_[3]++;
}
void
Foo_i::op5(ACE_ENV_SINGLE_ARG_DECL)
ACE_THROW_SPEC((CORBA::SystemException, FooException))
{
this->op_count_[4]++;
ACE_THROW (FooException());
}
void
Foo_i::done(ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
ACE_THROW_SPEC((CORBA::SystemException))
{
TheAppShutdown->client_done();
}
void
Foo_i::gather_stats(Foo_Statistics& stats)
{
for (unsigned i = 0; i < 5; i++)
{
stats.actual(i + 1, this->op_count_[i]);
}
}
|