OSDN Git Service

FIRST REPOSITORY
[eos/hostdependOTHERS.git] / I386LINUX / util / I386LINUX / doc / mico / examples / bench / bench_impl.h
1 #include "bench.h"
2 #ifdef _WIN32
3 #include <iostream>
4 #else
5 #ifdef HAVE_ANSI_CPLUSPLUS_HEADERS
6 #include <iostream>
7 #else // HAVE_ANSI_CPLUSPLUS_HEADERS
8 #include <iostream.h>
9 #endif // HAVE_ANSI_CPLUSPLUS_HEADERS
10 #endif // _WIN32
11
12 class Bench_impl : virtual public Bench_skel {
13     Bench_var _bench;
14     CORBA::Long _level;
15 public:
16     void f ()
17     {
18     }
19     void sync ()
20     {
21     }
22     void g ()
23     {
24         if (--_level > 0)
25             _bench->g();
26     }
27     void connect (Bench_ptr b, CORBA::Long l)
28     {
29         _bench = Bench::_duplicate (b);
30         _level = l;
31     }
32 };
33
34 #ifdef USE_POA
35 class Bench_impl3 : virtual public POA_Bench {
36 public:
37     Bench_var _bench;
38     CORBA::Long _level;
39 public:
40     void f ()
41     {
42     }
43     void sync ()
44     {
45     }
46     void g ()
47     {
48         if (--_level > 0)
49             _bench->g();
50     }
51     void connect (Bench_ptr b, CORBA::Long l)
52     {
53         _bench = Bench::_duplicate (b);
54         _level = l;
55     }
56 };
57 #endif
58