summaryrefslogtreecommitdiff
path: root/TAO/tests/POA/TIE/test_i.h
blob: 0cdc235ffad29ed6e7bde284e34ed35b7eb23f0b (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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
// -*- C++ -*-

//=============================================================================
/**
 *  @file     test_i.h
 *
 *   Defines implementation classes for the interfaces
 *
 *  @author  Irfan Pyarali
 */
//=============================================================================


#include "testS.h"

class Tie_i
{
public:
  // constructor - takes a POA and a value parameter
  Tie_i (CORBA::Long value);

  /// Destructor.
  virtual ~Tie_i ();

  // Simple doit method
  virtual CORBA::Long doit ();

protected:
  CORBA::Long value_;
};

class A_i : public POA_A
{
public:
  // constructor - takes a POA and a value parameter
  A_i (CORBA::Long value,
       PortableServer::POA_ptr poa);

  // Simple doit method
  virtual CORBA::Long doit ();

  // Returns the Default POA of this Servant object
  virtual PortableServer::POA_ptr _default_POA ();

protected:
  CORBA::Long value_;

  /// Default poa associated with this servant
  PortableServer::POA_var poa_;
};

class Outer_i
{
public:
  class B_i : public POA_Outer::B
  {
  public:
    // constructor - takes a POA and a value parameter
    B_i (CORBA::Long value,
         PortableServer::POA_ptr poa);

    // Simple doit method
    virtual CORBA::Long doit ();

    // Returns the Default POA of this Servant object
    virtual PortableServer::POA_ptr _default_POA ();

  protected:
    CORBA::Long value_;

    /// Default poa associated with this servant
    PortableServer::POA_var poa_;
  };

  class Inner_i
  {
  public:
    class C_i : public POA_Outer::Inner::C
    {
    public:
      // constructor - takes a POA and a value parameter
      C_i (CORBA::Long value,
           PortableServer::POA_ptr poa);

      // Simple doit method
      virtual CORBA::Long doit ();

      // Returns the Default POA of this Servant object
      virtual PortableServer::POA_ptr _default_POA ();

    protected:
      CORBA::Long value_;

      /// Default poa associated with this servant
      PortableServer::POA_var poa_;
    };
  };
};