00001
00002
00003 #ifndef COS_TRADINGREPOS_IDL
00004 #define COS_TRADINGREPOS_IDL
00005
00006 #include <orbdefs.idl>
00007
00008 #include <CosTrading.idl>
00009
00010 #pragma prefix "omg.org"
00011
00017 module CosTradingRepos
00018 {
00023 interface ServiceTypeRepository
00024 {
00025
00026 typedef sequence <CosTrading::ServiceTypeName> ServiceTypeNameSeq;
00027
00028
00039 enum PropertyMode
00040 {
00041 PROP_NORMAL,
00042 PROP_READONLY,
00043 PROP_MANDATORY,
00044 PROP_MANDATORY_READONLY
00045 };
00046
00055 enum ListOption
00056 {
00057 all,
00058 since
00059 };
00060
00066
00067 struct PropStruct
00068 {
00069 CosTrading::PropertyName name;
00070 CORBA::TypeCode value_type;
00071 PropertyMode mode;
00072 };
00073 typedef sequence <PropStruct> PropStructSeq;
00074
00075
00076
00077 typedef CosTrading::Istring Identifier;
00078
00079
00086 struct IncarnationNumber
00087 {
00088 unsigned long high;
00089 unsigned long low;
00090 };
00091
00099 struct TypeStruct
00100 {
00101 Identifier if_name;
00102 PropStructSeq props;
00103 ServiceTypeNameSeq super_types;
00104 boolean masked;
00105 IncarnationNumber incarnation;
00106 };
00107
00114
00115 union SpecifiedServiceTypes switch (ListOption)
00116 {
00117 case since: IncarnationNumber incarnation;
00118 };
00119
00120 exception ServiceTypeExists
00121 {
00122 CosTrading::ServiceTypeName name;
00123 };
00124 exception InterfaceTypeMismatch
00125 {
00126 CosTrading::ServiceTypeName base_service;
00127 Identifier base_if;
00128 CosTrading::ServiceTypeName derived_service;
00129 Identifier derived_if;
00130 };
00131 exception HasSubTypes
00132 {
00133 CosTrading::ServiceTypeName the_type;
00134 CosTrading::ServiceTypeName sub_type;
00135 };
00136 exception AlreadyMasked
00137 {
00138 CosTrading::ServiceTypeName name;
00139 };
00140 exception NotMasked
00141 {
00142 CosTrading::ServiceTypeName name;
00143 };
00144 exception ValueTypeRedefinition
00145 {
00146 CosTrading::ServiceTypeName type_1;
00147 PropStruct definition_1;
00148 CosTrading::ServiceTypeName type_2;
00149 PropStruct definition_2;
00150 };
00151 exception DuplicateServiceTypeName
00152 {
00153 CosTrading::ServiceTypeName name;
00154 };
00155
00158 readonly attribute IncarnationNumber incarnation;
00159
00185
00186 IncarnationNumber add_type
00187 (
00188 in CosTrading::ServiceTypeName name,
00189 in Identifier if_name,
00190 in PropStructSeq props,
00191 in ServiceTypeNameSeq super_types
00192 )
00193 raises
00194 (
00195 CosTrading::IllegalServiceType,
00196 ServiceTypeExists,
00197 InterfaceTypeMismatch,
00198 CosTrading::IllegalPropertyName,
00199 CosTrading::DuplicatePropertyName,
00200 ValueTypeRedefinition,
00201 CosTrading::UnknownServiceType,
00202 DuplicateServiceTypeName
00203 );
00204
00215
00216 void remove_type
00217 (
00218 in CosTrading::ServiceTypeName name
00219 )
00220 raises
00221 (
00222 CosTrading::IllegalServiceType,
00223 CosTrading::UnknownServiceType,
00224 HasSubTypes
00225 );
00226
00234
00235 ServiceTypeNameSeq list_types (in SpecifiedServiceTypes which_types);
00236
00237
00252 TypeStruct describe_type
00253 (
00254 in CosTrading::ServiceTypeName name
00255 )
00256 raises
00257 (
00258 CosTrading::IllegalServiceType,
00259 CosTrading::UnknownServiceType
00260 );
00261
00276 TypeStruct fully_describe_type
00277 (
00278 in CosTrading::ServiceTypeName name
00279 )
00280 raises
00281 (
00282 CosTrading::IllegalServiceType,
00283 CosTrading::UnknownServiceType
00284 );
00285
00298 void mask_type
00299 (
00300 in CosTrading::ServiceTypeName name
00301 )
00302 raises
00303 (
00304 CosTrading::IllegalServiceType,
00305 CosTrading::UnknownServiceType,
00306 AlreadyMasked
00307 );
00308
00321 void unmask_type
00322 (
00323 in CosTrading::ServiceTypeName name
00324 )
00325 raises
00326 (
00327 CosTrading::IllegalServiceType,
00328 CosTrading::UnknownServiceType,
00329 NotMasked
00330 );
00331 };
00332 };
00333
00334 #endif