Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef TAO_STRUCT_TYPECODE_H
00018 #define TAO_STRUCT_TYPECODE_H
00019
00020 #include "ace/pre.h"
00021
00022 #include "tao/AnyTypeCode/TypeCode.h"
00023
00024 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00025 # pragma once
00026 #endif
00027
00028 #include "tao/AnyTypeCode/TypeCode_Base_Attributes.h"
00029
00030 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00031
00032 namespace TAO
00033 {
00034 namespace TypeCode
00035 {
00036 template<typename StringType, typename TypeCodeType> struct Struct_Field;
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047 template <typename StringType,
00048 typename TypeCodeType,
00049 class FieldArrayType,
00050 class RefCountPolicy>
00051 class Struct
00052 : public CORBA::TypeCode,
00053 private RefCountPolicy
00054 {
00055 public:
00056
00057
00058 Struct (CORBA::TCKind kind,
00059 char const * id,
00060 char const * name,
00061 FieldArrayType const & fields,
00062 CORBA::ULong nfields);
00063
00064
00065 Struct (CORBA::TCKind kind, char const * id);
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076 virtual bool tao_marshal (TAO_OutputCDR & cdr, CORBA::ULong offset) const;
00077 virtual void tao_duplicate (void);
00078 virtual void tao_release (void);
00079
00080
00081 protected:
00082
00083
00084
00085
00086
00087
00088
00089
00090
00091
00092 virtual CORBA::Boolean equal_i (CORBA::TypeCode_ptr tc) const;
00093 virtual CORBA::Boolean equivalent_i (CORBA::TypeCode_ptr tc) const;
00094 virtual CORBA::TypeCode_ptr get_compact_typecode_i (void) const;
00095 virtual char const * id_i (void) const;
00096 virtual char const * name_i (void) const;
00097 virtual CORBA::ULong member_count_i (void) const;
00098 virtual char const * member_name_i (CORBA::ULong index) const;
00099 virtual CORBA::TypeCode_ptr member_type_i (CORBA::ULong index) const;
00100
00101
00102 protected:
00103
00104
00105
00106
00107
00108
00109
00110
00111
00112
00113
00114
00115
00116
00117
00118 Base_Attributes<StringType> base_attributes_;
00119
00120
00121 CORBA::ULong nfields_;
00122
00123
00124
00125 FieldArrayType fields_;
00126
00127
00128
00129 };
00130
00131 }
00132 }
00133
00134 TAO_END_VERSIONED_NAMESPACE_DECL
00135
00136 #ifdef __ACE_INLINE__
00137 # include "tao/AnyTypeCode/Struct_TypeCode.inl"
00138 #endif
00139
00140 #ifdef ACE_TEMPLATES_REQUIRE_SOURCE
00141 # include "tao/AnyTypeCode/Struct_TypeCode.cpp"
00142 #endif
00143
00144 #ifdef ACE_TEMPLATES_REQUIRE_PRAGMA
00145 # pragma implementation ("Struct_TypeCode.cpp")
00146 #endif
00147
00148
00149 #include "ace/post.h"
00150
00151 #endif