Merge pull request #1844 from jrw972/monterey
[ACE_TAO.git] / TAO / tests / Faults / test_i.h
blob884e62ff26db6421381bf1a99ba55d2e93cd2414
2 //=============================================================================
3 /**
4 * @file test_i.h
6 * @author Carlos O'Ryan
7 */
8 //=============================================================================
11 #ifndef TAO_FAILURE_TEST_I_H
12 #define TAO_FAILURE_TEST_I_H
14 #include "testS.h"
16 class Callback_i
17 : public virtual POA_Callback
19 // = TITLE
20 // A callback object to shutdown the "client"
22 // = DESCRIPTION
23 // To test that the server can tolerate client crashes the server
24 // receives a callback object.
26 public:
27 /// ctor
28 Callback_i (CORBA::ORB_ptr orb);
30 /// The callback method
31 void shutdown (CORBA::Boolean is_clean);
33 private:
34 /// The orb
35 CORBA::ORB_var orb_;
38 /**
39 * @class Simple_Server_i
41 * @brief Simpler Server implementation
43 * Implements the Simple_Server interface in test.idl
45 class Simple_Server_i : public POA_Simple_Server
47 public:
48 /// ctor
49 Simple_Server_i (CORBA::ORB_ptr orb);
51 // = The Simple_Server methods.
52 CORBA::Long test_method (CORBA::Boolean do_callback,
53 CORBA::Boolean is_clean,
54 Callback_ptr callback);
56 void shutdown_now (CORBA::Boolean is_clean);
58 void shutdown (void);
60 private:
61 /// The ORB
62 CORBA::ORB_var orb_;
65 /**
66 * @class Middle_i
68 * @brief Another implementation of the simple server...
70 * Implements the Simple_Server interface in test.idl
72 class Middle_i : public virtual POA_Simple_Server
74 public:
75 /// ctor
76 Middle_i (CORBA::ORB_ptr orb,
77 Simple_Server_ptr server);
79 // = The Simple_Server methods.
80 CORBA::Long test_method (CORBA::Boolean do_callback,
81 CORBA::Boolean is_clean,
82 Callback_ptr callback);
84 void shutdown_now (CORBA::Boolean is_clean);
86 void shutdown (void);
88 private:
89 /// The ORB
90 CORBA::ORB_var orb_;
92 /// The real server
93 Simple_Server_var server_;
96 #if defined(__ACE_INLINE__)
97 #include "test_i.inl"
98 #endif /* __ACE_INLINE__ */
100 #endif /* TAO_FAILURE_TEST_I_H */