3 //=============================================================================
9 //=============================================================================
11 #ifndef TAO_SEQ_VAR_T_H
12 #define TAO_SEQ_VAR_T_H
14 #include /**/ "ace/pre.h"
16 #if !defined (ACE_LACKS_PRAGMA_ONCE)
18 #endif /* ACE_LACKS_PRAGMA_ONCE */
20 #include /**/ "tao/Versioned_Namespace.h"
22 #include "tao/Basic_Types.h"
24 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
27 * @class TAO_Seq_Var_Base_T
29 * @brief Parametrized implementation of _var base class for sequences
32 class TAO_Seq_Var_Base_T
35 typedef typename
T::subscript_type T_elem
;
37 TAO_Seq_Var_Base_T ();
38 TAO_Seq_Var_Base_T (T
*);
39 TAO_Seq_Var_Base_T (const TAO_Seq_Var_Base_T
<T
> &);
41 ~TAO_Seq_Var_Base_T ();
44 const T
*operator-> () const;
46 operator const T
& () const;
48 operator T
& () const;
50 typedef const T
& _in_type
;
51 typedef T
& _inout_type
;
52 typedef T
*& _out_type
;
53 typedef T
* _retn_type
;
55 // in, inout, out, _retn
62 _retn_type
ptr () const;
69 * @class TAO_FixedSeq_Var_T
71 * @brief Parametrized implementation of _var class for sequences
72 * whose element is of fixed size..
75 class TAO_FixedSeq_Var_T
: public TAO_Seq_Var_Base_T
<T
>
78 typedef typename
T::subscript_type T_elem
;
79 typedef typename
T::const_subscript_type T_const_elem
;
81 TAO_FixedSeq_Var_T ();
82 TAO_FixedSeq_Var_T (T
*);
83 TAO_FixedSeq_Var_T (const TAO_FixedSeq_Var_T
<T
> &);
85 // Fixed-size base types only.
86 TAO_FixedSeq_Var_T (const T
&);
88 TAO_FixedSeq_Var_T
& operator= (T
*);
89 TAO_FixedSeq_Var_T
& operator= (const TAO_FixedSeq_Var_T
<T
> &);
91 T_elem
operator[] (CORBA::ULong index
);
92 T_const_elem
operator[] (CORBA::ULong index
) const;
94 /// Fixed-size base types only.
95 TAO_FixedSeq_Var_T
& operator= (const T
&);
99 * @class TAO_VarSeq_Var_T
101 * @brief Parametrized implementation of _var class for sequences
102 * whose element is of variable size..
104 template <typename T
>
105 class TAO_VarSeq_Var_T
: public TAO_Seq_Var_Base_T
<T
>
108 typedef typename
T::subscript_type T_elem
;
109 typedef typename
T::const_subscript_type T_const_elem
;
112 TAO_VarSeq_Var_T (T
*);
113 TAO_VarSeq_Var_T (const TAO_VarSeq_Var_T
<T
> &);
115 TAO_VarSeq_Var_T
& operator= (T
*);
116 TAO_VarSeq_Var_T
& operator= (const TAO_VarSeq_Var_T
<T
> &);
118 T_elem
operator[] (CORBA::ULong index
);
119 T_const_elem
operator[] (CORBA::ULong index
) const;
121 /// Variable-size base types only.
125 TAO_END_VERSIONED_NAMESPACE_DECL
127 #if defined (__ACE_INLINE__)
128 #include "tao/Seq_Var_T.inl"
129 #endif /* defined INLINE */
131 #include "tao/Seq_Var_T.cpp"
133 #include /**/ "ace/post.h"
135 #endif /* TAO_SEQ_VAROUT_T_H */