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
99
100
101
102
103
104
105
106
107
108
109
110
|
// -*- C++ -*-
//=============================================================================
/**
* @file Pseudo_VarOut_T.h
*
* $Id$
*
* @author Jeff Parsons
*/
//=============================================================================
#ifndef TAO_PSEUDO_VAROUT_T_H
#define TAO_PSEUDO_VAROUT_T_H
#include "ace/pre.h"
#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */
/**
* @class TAO_Pseudo_Var_T
*
* @brief Parametrized implementation of _var class for
* TypeCode, Object, AbstractBase, NamedValue, NVList,
* Principal, Request, Context, ORB, LocalObject,
* and Environment.
*
*/
template <typename T>
class TAO_Pseudo_Var_T
{
public:
TAO_Pseudo_Var_T (void);
TAO_Pseudo_Var_T (T *);
TAO_Pseudo_Var_T (const TAO_Pseudo_Var_T<T> &);
~TAO_Pseudo_Var_T (void);
TAO_Pseudo_Var_T<T> & operator= (T *);
TAO_Pseudo_Var_T<T> & operator= (const TAO_Pseudo_Var_T<T> &);
T * operator-> (void) const;
operator const T *& () const;
operator T *& ();
T * in (void) const;
T *& inout (void);
T *& out (void);
T * _retn (void);
// TAO extension.
T * ptr (void) const;
private:
T * ptr_;
};
/**
* @class TAO_Pseudo_Out_T
*
* @brief Parametrized implementation of _out class for
* TypeCode, Object, AbstractBase, NamedValue, NVList,
* Principal, Request, Context, ORB, LocalObject,
* and Environment.
*
*/
template <typename T, typename T_var>
class TAO_Pseudo_Out_T
{
public:
TAO_Pseudo_Out_T (T *&);
TAO_Pseudo_Out_T (T_var &);
TAO_Pseudo_Out_T (const TAO_Pseudo_Out_T<T,T_var> &);
TAO_Pseudo_Out_T<T,T_var> & operator= (const TAO_Pseudo_Out_T<T,T_var> &);
TAO_Pseudo_Out_T<T,T_var> & operator= (T *);
operator T *& ();
T *& ptr (void);
T * operator-> (void);
private:
T *& ptr_;
/// Assignment from _var not allowed.
TAO_Pseudo_Out_T<T,T_var> & operator= (const T_var &);
};
#if defined (__ACE_INLINE__)
#include "tao/Pseudo_VarOut_T.inl"
#endif /* __ACE_INLINE__ */
#if defined (ACE_TEMPLATES_REQUIRE_SOURCE)
#include "tao/Pseudo_VarOut_T.cpp"
#endif /* ACE_TEMPLATES_REQUIRE_SOURCE */
#if defined (ACE_TEMPLATES_REQUIRE_PRAGMA)
#pragma implementation ("Pseudo_VarOut_T.cpp")
#endif /* ACE_TEMPLATES_REQUIRE_PRAGMA */
#include "ace/post.h"
#endif /* TAO_PSEUDO_VAROUT_T_H */
|