00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050 #ifndef _IFR_BASIC_IDL_
00051 #define _IFR_BASIC_IDL_
00052
00053 #include "tao/IFR_Client/IFR_Base.pidl"
00054 #include "tao/ParameterMode.pidl"
00055
00056 module CORBA
00057 {
00058 typeprefix CORBA "omg.org";
00059
00060 interface PrimitiveDef;
00061 interface StringDef;
00062 interface SequenceDef;
00063 interface ArrayDef;
00064 interface WstringDef;
00065 interface FixedDef;
00066
00067 enum PrimitiveKind
00068 {
00069 pk_null,
00070 pk_void,
00071 pk_short,
00072 pk_long,
00073 pk_ushort,
00074 pk_ulong,
00075 pk_float,
00076 pk_double,
00077 pk_boolean,
00078 pk_char,
00079 pk_octet,
00080 pk_any,
00081 pk_TypeCode,
00082 pk_Principal,
00083 pk_string,
00084 pk_objref,
00085 pk_longlong,
00086 pk_ulonglong,
00087 pk_longdouble,
00088 pk_wchar,
00089 pk_wstring,
00090 pk_value_base
00091 };
00092
00093 interface Repository : Container
00094 {
00095
00096 Contained lookup_id (
00097 in RepositoryId search_id
00098 );
00099 TypeCode get_canonical_typecode (
00100 in TypeCode tc
00101 );
00102 PrimitiveDef get_primitive (
00103 in PrimitiveKind kind
00104 );
00105
00106 StringDef create_string (
00107 in unsigned long bound
00108 );
00109 WstringDef create_wstring (
00110 in unsigned long bound
00111 );
00112 SequenceDef create_sequence (
00113 in unsigned long bound,
00114 in IDLType element_type
00115 );
00116 ArrayDef create_array (
00117 in unsigned long length,
00118 in IDLType element_type
00119 );
00120 FixedDef create_fixed (
00121 in unsigned short digits,
00122 in short scale
00123 );
00124 };
00125
00126 interface ModuleDef : Container, Contained
00127 {
00128 };
00129
00130 struct ModuleDescription
00131 {
00132 Identifier name;
00133 RepositoryId id;
00134 RepositoryId defined_in;
00135 VersionSpec version;
00136 };
00137
00138 interface ConstantDef : Contained
00139 {
00140 readonly attribute TypeCode type;
00141 attribute IDLType type_def;
00142 attribute any value;
00143 };
00144
00145 struct ConstantDescription
00146 {
00147 Identifier name;
00148 RepositoryId id;
00149 RepositoryId defined_in;
00150 VersionSpec version;
00151 TypeCode type;
00152 any value;
00153 };
00154
00155 interface StructDef : TypedefDef, Container
00156 {
00157 attribute StructMemberSeq members;
00158 };
00159
00160 interface UnionDef : TypedefDef, Container
00161 {
00162 readonly attribute TypeCode discriminator_type;
00163 attribute IDLType discriminator_type_def;
00164 attribute UnionMemberSeq members;
00165 };
00166
00167 interface EnumDef : TypedefDef
00168 {
00169 attribute EnumMemberSeq members;
00170 };
00171
00172 interface AliasDef : TypedefDef
00173 {
00174 attribute IDLType original_type_def;
00175 };
00176
00177 interface NativeDef : TypedefDef
00178 {
00179 };
00180
00181 interface PrimitiveDef: IDLType
00182 {
00183 readonly attribute PrimitiveKind kind;
00184 };
00185
00186 interface StringDef : IDLType
00187 {
00188 attribute unsigned long bound;
00189 };
00190
00191 interface WstringDef : IDLType
00192 {
00193 attribute unsigned long bound;
00194 };
00195
00196 interface SequenceDef : IDLType
00197 {
00198 attribute unsigned long bound;
00199 readonly attribute TypeCode element_type;
00200 attribute IDLType element_type_def;
00201 };
00202
00203 interface ArrayDef : IDLType
00204 {
00205 attribute unsigned long length;
00206 readonly attribute TypeCode element_type;
00207 attribute IDLType element_type_def;
00208 };
00209
00210 interface ExceptionDef : Contained, Container
00211 {
00212 readonly attribute TypeCode type;
00213 attribute StructMemberSeq members;
00214 };
00215
00216 typedef sequence <ExceptionDef> ExceptionDefSeq;
00217
00218 enum AttributeMode
00219 {
00220 ATTR_NORMAL,
00221 ATTR_READONLY
00222 };
00223
00224 interface AttributeDef : Contained
00225 {
00226 readonly attribute TypeCode type;
00227 attribute IDLType type_def;
00228 attribute AttributeMode mode;
00229 };
00230
00231 struct AttributeDescription
00232 {
00233 Identifier name;
00234 RepositoryId id;
00235 RepositoryId defined_in;
00236 VersionSpec version;
00237 TypeCode type;
00238 AttributeMode mode;
00239 };
00240
00241 struct ExtAttributeDescription
00242 {
00243 Identifier name;
00244 RepositoryId id;
00245 RepositoryId defined_in;
00246 VersionSpec version;
00247 TypeCode type;
00248 AttributeMode mode;
00249 ExcDescriptionSeq get_exceptions;
00250 ExcDescriptionSeq put_exceptions;
00251 };
00252
00253 interface ExtAttributeDef : AttributeDef
00254 {
00255
00256 attribute ExcDescriptionSeq get_exceptions;
00257 attribute ExcDescriptionSeq set_exceptions;
00258
00259 ExtAttributeDescription describe_attribute ();
00260 };
00261
00262 enum OperationMode
00263 {
00264 OP_NORMAL,
00265 OP_ONEWAY
00266 };
00267
00268
00269
00270
00271
00272
00273
00274
00275
00276
00277 struct ParameterDescription
00278 {
00279 Identifier name;
00280 TypeCode type;
00281 IDLType type_def;
00282 ParameterMode mode;
00283 };
00284
00285 typedef sequence <ParameterDescription> ParDescriptionSeq;
00286 typedef Identifier ContextIdentifier;
00287 typedef sequence <ContextIdentifier> ContextIdSeq;
00288
00289 interface OperationDef : Contained
00290 {
00291 readonly attribute TypeCode result;
00292 attribute IDLType result_def;
00293 attribute ParDescriptionSeq params;
00294 attribute OperationMode mode;
00295 attribute ContextIdSeq contexts;
00296 attribute ExceptionDefSeq exceptions;
00297 };
00298
00299 struct OperationDescription
00300 {
00301 Identifier name;
00302 RepositoryId id;
00303 RepositoryId defined_in;
00304 VersionSpec version;
00305 TypeCode result;
00306 OperationMode mode;
00307 ContextIdSeq contexts;
00308 ParDescriptionSeq parameters;
00309 ExcDescriptionSeq exceptions;
00310 };
00311
00312 typedef sequence <RepositoryId> RepositoryIdSeq;
00313 typedef sequence <OperationDescription> OpDescriptionSeq;
00314 typedef sequence <AttributeDescription> AttrDescriptionSeq;
00315 typedef sequence <ExtAttributeDescription> ExtAttrDescriptionSeq;
00316
00317 interface InterfaceDef : Container, Contained, IDLType
00318 {
00319
00320 attribute InterfaceDefSeq base_interfaces;
00321
00322 boolean is_a (
00323 in RepositoryId interface_id
00324 );
00325
00326 struct FullInterfaceDescription
00327 {
00328 Identifier name;
00329 RepositoryId id;
00330 RepositoryId defined_in;
00331 VersionSpec version;
00332 OpDescriptionSeq operations;
00333 AttrDescriptionSeq attributes;
00334 RepositoryIdSeq base_interfaces;
00335 TypeCode type;
00336 };
00337
00338 FullInterfaceDescription describe_interface ();
00339
00340
00341 AttributeDef create_attribute ( in RepositoryId id,
00342 in Identifier name,
00343 in VersionSpec version,
00344 in IDLType type,
00345 in AttributeMode mode );
00346
00347 OperationDef create_operation ( in RepositoryId id,
00348 in Identifier name,
00349 in VersionSpec version,
00350 in IDLType result,
00351 in OperationMode mode,
00352 in ParDescriptionSeq params,
00353 in ExceptionDefSeq exceptions,
00354 in ContextIdSeq contexts );
00355 };
00356
00357 struct InterfaceDescription
00358 {
00359 Identifier name;
00360 RepositoryId id;
00361 RepositoryId defined_in;
00362 VersionSpec version;
00363 RepositoryIdSeq base_interfaces;
00364 };
00365
00366 interface InterfaceAttrExtension
00367 {
00368
00369 struct ExtFullInterfaceDescription
00370 {
00371 Identifier name;
00372 RepositoryId id;
00373 RepositoryId defined_in;
00374 VersionSpec version;
00375 OpDescriptionSeq operations;
00376 ExtAttrDescriptionSeq attributes;
00377 RepositoryIdSeq base_interfaces;
00378 TypeCode type;
00379 };
00380
00381 ExtFullInterfaceDescription describe_ext_interface ();
00382
00383
00384 ExtAttributeDef create_ext_attribute ( in RepositoryId id,
00385 in Identifier name,
00386 in VersionSpec version,
00387 in IDLType type,
00388 in AttributeMode mode,
00389 in ExceptionDefSeq get_exceptions,
00390 in ExceptionDefSeq set_exceptions );
00391 };
00392
00393 interface ExtInterfaceDef : InterfaceDef, InterfaceAttrExtension
00394 {
00395 };
00396
00397 interface AbstractInterfaceDef : InterfaceDef
00398 {
00399 };
00400
00401 interface ExtAbstractInterfaceDef : AbstractInterfaceDef,
00402 InterfaceAttrExtension
00403 {
00404 };
00405
00406 interface LocalInterfaceDef : InterfaceDef
00407 {
00408 };
00409
00410 interface ExtLocalInterfaceDef : LocalInterfaceDef,
00411 InterfaceAttrExtension
00412 {
00413 };
00414 };
00415
00416 #endif