src/share/classes/org/omg/CORBA/ir.idl

changeset 1
55540e827aef
child 5
5e61d5df6258
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/src/share/classes/org/omg/CORBA/ir.idl	Sat Dec 01 00:00:00 2007 +0000
     1.3 @@ -0,0 +1,793 @@
     1.4 +/*
     1.5 + * Copyright 1997-2000 Sun Microsystems, Inc.  All Rights Reserved.
     1.6 + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     1.7 + *
     1.8 + * This code is free software; you can redistribute it and/or modify it
     1.9 + * under the terms of the GNU General Public License version 2 only, as
    1.10 + * published by the Free Software Foundation.  Sun designates this
    1.11 + * particular file as subject to the "Classpath" exception as provided
    1.12 + * by Sun in the LICENSE file that accompanied this code.
    1.13 + *
    1.14 + * This code is distributed in the hope that it will be useful, but WITHOUT
    1.15 + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    1.16 + * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    1.17 + * version 2 for more details (a copy is included in the LICENSE file that
    1.18 + * accompanied this code).
    1.19 + *
    1.20 + * You should have received a copy of the GNU General Public License version
    1.21 + * 2 along with this work; if not, write to the Free Software Foundation,
    1.22 + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
    1.23 + *
    1.24 + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
    1.25 + * CA 95054 USA or visit www.sun.com if you need additional information or
    1.26 + * have any questions.
    1.27 + */
    1.28 +
    1.29 +/*
    1.30 + * This file contains OMG IDL from  CORBA V2.0, July 1995.
    1.31 + * It also contains the TypeCode creation APIs in CORBA::ORB
    1.32 + **/
    1.33 +
    1.34 +#pragma prefix "omg.org"
    1.35 +//#pragma javaPackage org.omg
    1.36 +
    1.37 +module CORBA {
    1.38 +    typedef string Identifier;
    1.39 +    typedef string ScopedName;
    1.40 +    typedef string RepositoryId;
    1.41 +
    1.42 +    enum DefinitionKind {
    1.43 +	dk_none, dk_all,
    1.44 +	dk_Attribute, dk_Constant, dk_Exception, dk_Interface,
    1.45 +	dk_Module, dk_Operation, dk_Typedef,
    1.46 +	dk_Alias, dk_Struct, dk_Union, dk_Enum,
    1.47 +	dk_Primitive, dk_String, dk_Sequence, dk_Array,
    1.48 +	dk_Repository,
    1.49 +	dk_Wstring, dk_Fixed,
    1.50 +	dk_Value, dk_ValueBox, dk_ValueMember, // orbos 98-01-18: Objects By Value
    1.51 +	dk_Native
    1.52 +    };
    1.53 +
    1.54 +
    1.55 +    interface IRObject
    1.56 +    /**
    1.57 +      An IRObject IDL interface represents the most generic interface
    1.58 +      from which all other Interface Repository interfaces are derived,
    1.59 +      even the Repository itself.
    1.60 +     */
    1.61 +    {
    1.62 +	// read interface
    1.63 +	readonly attribute DefinitionKind def_kind;
    1.64 +
    1.65 +	// write interface
    1.66 +	void destroy ();
    1.67 +    };
    1.68 +
    1.69 +
    1.70 +
    1.71 +    typedef string VersionSpec;
    1.72 +
    1.73 +    interface Contained;
    1.74 +    interface Repository;
    1.75 +    interface Container;
    1.76 +
    1.77 +    interface Contained : IRObject
    1.78 +    /**
    1.79 +       The Contained Interface is inherited by all Interface Repository
    1.80 +       interfaces that are contained by other objects.
    1.81 +     */
    1.82 +    {
    1.83 +	// read/write interface
    1.84 +
    1.85 +	attribute RepositoryId id;
    1.86 +	attribute Identifier name;
    1.87 +	attribute VersionSpec version;
    1.88 +
    1.89 +	// read interface
    1.90 +
    1.91 +	readonly attribute Container defined_in;
    1.92 +	readonly attribute ScopedName absolute_name;
    1.93 +	readonly attribute Repository containing_repository;
    1.94 +
    1.95 +	struct Description {
    1.96 +	    DefinitionKind kind;
    1.97 +	    any value;
    1.98 +	};
    1.99 +
   1.100 +	Description describe ();
   1.101 +
   1.102 +	// write interface
   1.103 +
   1.104 +	void move (
   1.105 +	    in Container new_container,
   1.106 +	    in Identifier new_name,
   1.107 +	    in VersionSpec new_version
   1.108 +	    );
   1.109 +    };
   1.110 +
   1.111 +
   1.112 +    interface ModuleDef;
   1.113 +    interface ConstantDef;
   1.114 +    interface IDLType;
   1.115 +    interface StructDef;
   1.116 +    interface UnionDef;
   1.117 +    interface EnumDef;
   1.118 +    interface AliasDef;
   1.119 +    interface InterfaceDef;
   1.120 +    interface ExceptionDef;
   1.121 +    interface ValueDef;		// orbos 98-01-18: Objects By Value
   1.122 +    interface ValueMemberDef;	// orbos 98-01-18: Objects By Value
   1.123 +    interface ValueBoxDef;	// orbos 98-01-18: Objects By Value
   1.124 +    interface NativeDef;
   1.125 +
   1.126 +
   1.127 +    typedef sequence <InterfaceDef> InterfaceDefSeq;
   1.128 +
   1.129 +
   1.130 +    typedef sequence <Contained> ContainedSeq;
   1.131 +
   1.132 +    struct StructMember {
   1.133 +	Identifier name;
   1.134 +	TypeCode type;
   1.135 +	IDLType type_def;
   1.136 +    };
   1.137 +    typedef sequence <StructMember> StructMemberSeq;
   1.138 +
   1.139 +    struct UnionMember {
   1.140 +	Identifier name;
   1.141 +	any label;
   1.142 +	TypeCode type;
   1.143 +	IDLType type_def;
   1.144 +    };
   1.145 +    typedef sequence <UnionMember> UnionMemberSeq;
   1.146 +
   1.147 +
   1.148 +    typedef sequence <Identifier> EnumMemberSeq;
   1.149 +
   1.150 +    // orbos 98-01-18: Objects By Value -- begin
   1.151 +    typedef short Visibility;	
   1.152 +    const Visibility PRIVATE_MEMBER = 0; 
   1.153 +    const Visibility PUBLIC_MEMBER = 1;
   1.154 +
   1.155 +    struct ValueMember {
   1.156 +        Identifier name;
   1.157 +	RepositoryId id;
   1.158 +	RepositoryId defined_in;
   1.159 +	VersionSpec version;
   1.160 +        TypeCode type;
   1.161 +        IDLType type_def;
   1.162 +        Visibility access;
   1.163 +    };
   1.164 +    typedef sequence <ValueMember> ValueMemberSeq;
   1.165 +
   1.166 +    struct Initializer {
   1.167 +        StructMemberSeq members;
   1.168 +    };
   1.169 +    typedef sequence <Initializer> InitializerSeq;
   1.170 +
   1.171 +    typedef sequence <ValueDef> ValueDefSeq;
   1.172 +    
   1.173 +    // orbos 98-01-18: Objects By Value -- end
   1.174 +
   1.175 +
   1.176 +    interface Container : IRObject
   1.177 +    /**
   1.178 +      The Container interface is used to form a containment hierarchy
   1.179 +      in the Interface Repository. A Container can contain any number
   1.180 +      of objects derived from the Contained interface.
   1.181 +    */
   1.182 +    {
   1.183 +	// read interface
   1.184 +
   1.185 +	Contained lookup ( in ScopedName search_name);
   1.186 +
   1.187 +	ContainedSeq contents (
   1.188 +	    in DefinitionKind limit_type,
   1.189 +	    in boolean exclude_inherited
   1.190 +	    );
   1.191 +
   1.192 +	ContainedSeq lookup_name (
   1.193 +	    in Identifier search_name,
   1.194 +	    in long levels_to_search,
   1.195 +	    in DefinitionKind limit_type,
   1.196 +	    in boolean exclude_inherited
   1.197 +	    );
   1.198 +
   1.199 +	struct Description {
   1.200 +	    Contained contained_object;
   1.201 +	    DefinitionKind kind;
   1.202 +	    any value;
   1.203 +	};
   1.204 +
   1.205 +	typedef sequence<Description> DescriptionSeq;
   1.206 +
   1.207 +	DescriptionSeq describe_contents (
   1.208 +	    in DefinitionKind limit_type,
   1.209 +	    in boolean exclude_inherited,
   1.210 +	    in long max_returned_objs
   1.211 +	    );
   1.212 +
   1.213 +	// write interface
   1.214 +
   1.215 +	ModuleDef create_module (
   1.216 +	    in RepositoryId id,
   1.217 +	    in Identifier name,
   1.218 +	    in VersionSpec version
   1.219 +	    );
   1.220 +
   1.221 +	ConstantDef create_constant (
   1.222 +	    in RepositoryId id,
   1.223 +	    in Identifier name,
   1.224 +	    in VersionSpec version,
   1.225 +	    in IDLType type,
   1.226 +	    in any value
   1.227 +	    );
   1.228 +
   1.229 +	StructDef create_struct (
   1.230 +	    in RepositoryId id,
   1.231 +	    in Identifier name,
   1.232 +	    in VersionSpec version,
   1.233 +	    in StructMemberSeq members
   1.234 +	    );
   1.235 +
   1.236 +	UnionDef create_union (
   1.237 +	    in RepositoryId id,
   1.238 +	    in Identifier name,
   1.239 +	    in VersionSpec version,
   1.240 +	    in IDLType discriminator_type,
   1.241 +	    in UnionMemberSeq members
   1.242 +	    );
   1.243 +
   1.244 +	EnumDef create_enum (
   1.245 +	    in RepositoryId id,
   1.246 +	    in Identifier name,
   1.247 +	    in VersionSpec version,
   1.248 +	    in EnumMemberSeq members
   1.249 +	    );
   1.250 +
   1.251 +	AliasDef create_alias (
   1.252 +	    in RepositoryId id,
   1.253 +	    in Identifier name,
   1.254 +	    in VersionSpec version,
   1.255 +	    in IDLType original_type
   1.256 +	    );
   1.257 +
   1.258 +        ExceptionDef create_exception (
   1.259 +            in RepositoryId    id,
   1.260 +            in Identifier      name,
   1.261 +            in VersionSpec     version,
   1.262 +            in StructMemberSeq members
   1.263 +        );
   1.264 +
   1.265 +
   1.266 +	InterfaceDef create_interface (
   1.267 +	    in RepositoryId id,
   1.268 +	    in Identifier name,
   1.269 +	    in VersionSpec version,
   1.270 +	    in boolean is_abstract,
   1.271 +	    in InterfaceDefSeq base_interfaces
   1.272 +	    );
   1.273 +
   1.274 +	// orbos 98-01-18: Objects By Value
   1.275 +	ValueDef create_value(
   1.276 +	    in RepositoryId id,
   1.277 +	    in Identifier name,
   1.278 +	    in VersionSpec version,
   1.279 +	    in boolean is_custom,
   1.280 +	    in boolean is_abstract,
   1.281 +	    in octet flags,	// must be 0
   1.282 +	    in ValueDef base_value,
   1.283 +	    in boolean has_safe_base,
   1.284 +	    in ValueDefSeq abstract_base_values,
   1.285 +	    in InterfaceDefSeq supported_interfaces,
   1.286 +	    in InitializerSeq initializers
   1.287 +	    );
   1.288 +	
   1.289 +	// orbos 98-01-18: Objects By Value
   1.290 +	ValueBoxDef create_value_box(
   1.291 +	    in RepositoryId id,
   1.292 +	    in Identifier name,
   1.293 +	    in VersionSpec version,
   1.294 +	    in IDLType original_type_def
   1.295 +	    );
   1.296 +	
   1.297 +	NativeDef create_native(
   1.298 +	    in RepositoryId id,
   1.299 +	    in Identifier name,
   1.300 +	    in VersionSpec version
   1.301 +	    );
   1.302 +	
   1.303 +    };
   1.304 +
   1.305 +
   1.306 +
   1.307 +    interface IDLType : IRObject
   1.308 +    /**
   1.309 +       The IDLType interface is an abstract interface inherited by all
   1.310 +       IR objects that represent the OMG IDL types. It provides access
   1.311 +       to the TypeCode describing the type, and is used in defining the
   1.312 +       other interfaces wherever definitions of IDLType must be referenced.
   1.313 +    */
   1.314 +    {
   1.315 +	readonly attribute TypeCode type;
   1.316 +    };
   1.317 +
   1.318 +
   1.319 +
   1.320 +    interface PrimitiveDef;
   1.321 +    interface StringDef;
   1.322 +    interface SequenceDef;
   1.323 +    interface ArrayDef;
   1.324 +
   1.325 +    enum PrimitiveKind {
   1.326 +	pk_null, pk_void, pk_short, pk_long, pk_ushort, pk_ulong,
   1.327 +	pk_float, pk_double, pk_boolean, pk_char, pk_octet,
   1.328 +	pk_any, pk_TypeCode, pk_Principal, pk_string, pk_objref
   1.329 +    };
   1.330 +
   1.331 +    interface Repository : Container
   1.332 +    /**
   1.333 +      Repository is an interface that provides global access to the
   1.334 +      Interface Repository. Repository objects can contain constants,
   1.335 +      typedefs, exceptions, interfaces, and modules.
   1.336 +    */
   1.337 +    {
   1.338 +	// read interface
   1.339 +
   1.340 +	Contained lookup_id (in RepositoryId search_id);
   1.341 +
   1.342 +	PrimitiveDef get_primitive (in PrimitiveKind kind);
   1.343 +
   1.344 +	// write interface
   1.345 +
   1.346 +	StringDef create_string (in unsigned long bound);
   1.347 +
   1.348 +	SequenceDef create_sequence (
   1.349 +	    in unsigned long bound,
   1.350 +	    in IDLType element_type
   1.351 +	    );
   1.352 +
   1.353 +	ArrayDef create_array (
   1.354 +	    in unsigned long length,
   1.355 +	    in IDLType element_type
   1.356 +	    );
   1.357 +    };
   1.358 +
   1.359 +
   1.360 +    interface ModuleDef : Container, Contained
   1.361 +    /**
   1.362 +      A ModuleDef can contain constants, typedefs, exceptions, interfaces,
   1.363 +      and other module objects.
   1.364 +    */
   1.365 +    {
   1.366 +    };
   1.367 +
   1.368 +    struct ModuleDescription {
   1.369 +	Identifier name;
   1.370 +	RepositoryId id;
   1.371 +	RepositoryId defined_in;
   1.372 +	VersionSpec version;
   1.373 +    };
   1.374 +
   1.375 +
   1.376 +    interface ConstantDef : Contained
   1.377 +    /**
   1.378 +      A ConstantDef object defines a named constant.
   1.379 +    */
   1.380 +    {
   1.381 +	readonly attribute TypeCode type;
   1.382 +	attribute IDLType type_def;
   1.383 +	attribute any value;
   1.384 +    };
   1.385 +
   1.386 +    struct ConstantDescription {
   1.387 +	Identifier name;
   1.388 +	RepositoryId id;
   1.389 +	RepositoryId defined_in;
   1.390 +	VersionSpec version;
   1.391 +	TypeCode type;
   1.392 +	any value;
   1.393 +    };
   1.394 +
   1.395 +
   1.396 +    interface TypedefDef : Contained, IDLType
   1.397 +    /**
   1.398 +      TypedefDef is an abstract interface used as a base interface for
   1.399 +      all named non-object types(structures, unions, enumerations,
   1.400 +      aliases). The TypedefDef interface is not inherited by the definition
   1.401 +      objects for the primitive or anonymous types.
   1.402 +    */
   1.403 +    {
   1.404 +    };
   1.405 +
   1.406 +    struct TypeDescription {
   1.407 +	Identifier name;
   1.408 +	RepositoryId id;
   1.409 +	RepositoryId defined_in;
   1.410 +	VersionSpec version;
   1.411 +	TypeCode type;
   1.412 +    };
   1.413 +
   1.414 +
   1.415 +    interface StructDef : TypedefDef, Container
   1.416 +    /**
   1.417 +       A StructDef represents an OMG IDL structure definition.
   1.418 +    */
   1.419 +    {
   1.420 +	attribute StructMemberSeq members;
   1.421 +    };
   1.422 +
   1.423 +
   1.424 +    interface UnionDef : TypedefDef, Container
   1.425 +    /**
   1.426 +       A UnionDef represents an OMG IDL union definition.
   1.427 +     */
   1.428 +    {
   1.429 +	readonly attribute TypeCode discriminator_type;
   1.430 +	attribute IDLType discriminator_type_def;
   1.431 +	attribute UnionMemberSeq members;
   1.432 +    };
   1.433 +
   1.434 +
   1.435 +    interface EnumDef : TypedefDef
   1.436 +    /**
   1.437 +      A EnumDef represents an OMG IDL enum definition.
   1.438 +     */
   1.439 +    {
   1.440 +	attribute EnumMemberSeq members;
   1.441 +    };
   1.442 +
   1.443 +
   1.444 +    interface AliasDef : TypedefDef
   1.445 +    /**
   1.446 +       An AliasDef represents an OMG IDL typedef that aliases other
   1.447 +       definition.
   1.448 +    */
   1.449 +    {
   1.450 +	attribute IDLType original_type_def;
   1.451 +    };
   1.452 +
   1.453 +
   1.454 +    interface PrimitiveDef: IDLType
   1.455 +    /**
   1.456 +      A PrimitiveDef represents one of the IDL primitive types. As
   1.457 +      primitive types are unnamed, this interface is not derived from
   1.458 +      TypedefDef or Contained.
   1.459 +     */
   1.460 +    {
   1.461 +	readonly attribute PrimitiveKind kind;
   1.462 +    };
   1.463 +
   1.464 +
   1.465 +    interface StringDef : IDLType
   1.466 +    /**
   1.467 +      A StringDef represents an OMG IDL string type. As string
   1.468 +      types are anonymous, this interface is not derived from TypedefDef
   1.469 +      or Contained.
   1.470 +    */
   1.471 +    {
   1.472 +	attribute unsigned long bound;
   1.473 +    };
   1.474 +
   1.475 +
   1.476 +    interface SequenceDef : IDLType
   1.477 +    /**
   1.478 +      A SequenceDef represents an OMG IDL sequence type. As sequence
   1.479 +      types are anonymous, this interface is not derived from TypedefDef
   1.480 +      or Contained.
   1.481 +     */
   1.482 +    {
   1.483 +	attribute unsigned long bound;
   1.484 +	readonly attribute TypeCode element_type;
   1.485 +	attribute IDLType element_type_def;
   1.486 +    };
   1.487 +
   1.488 +    interface ArrayDef : IDLType
   1.489 +    /**
   1.490 +      An ArrayDef represents an OMG IDL array type. As array
   1.491 +      types are anonymous, this interface is not derived from TypedefDef
   1.492 +      or Contained.
   1.493 +    */
   1.494 +    {
   1.495 +	attribute unsigned long length;
   1.496 +	readonly attribute TypeCode element_type;
   1.497 +	attribute IDLType element_type_def;
   1.498 +    };
   1.499 +
   1.500 +
   1.501 +    interface ExceptionDef : Contained, Container
   1.502 +    /**
   1.503 +      An ExceptionDef represents an exception definition.
   1.504 +    */
   1.505 +    {
   1.506 +	readonly attribute TypeCode type;
   1.507 +	attribute StructMemberSeq members;
   1.508 +    };
   1.509 +    struct ExceptionDescription {
   1.510 +	Identifier name;
   1.511 +	RepositoryId id;
   1.512 +	RepositoryId defined_in;
   1.513 +	VersionSpec version;
   1.514 +	TypeCode type;
   1.515 +    };
   1.516 +
   1.517 +
   1.518 +
   1.519 +    enum AttributeMode {ATTR_NORMAL, ATTR_READONLY};
   1.520 +
   1.521 +    interface AttributeDef : Contained
   1.522 +    /**
   1.523 +      An AttributeDef represents the information that defines an
   1.524 +      attribute of an interface.
   1.525 +    */
   1.526 +    {
   1.527 +	readonly attribute TypeCode type;
   1.528 +	attribute IDLType type_def;
   1.529 +	attribute AttributeMode mode;
   1.530 +    };
   1.531 +
   1.532 +    struct AttributeDescription {
   1.533 +	Identifier name;
   1.534 +	RepositoryId id;
   1.535 +	RepositoryId defined_in;
   1.536 +	VersionSpec version;
   1.537 +	TypeCode type;
   1.538 +	AttributeMode mode;
   1.539 +    };
   1.540 +
   1.541 +
   1.542 +
   1.543 +    enum OperationMode {OP_NORMAL, OP_ONEWAY};
   1.544 +
   1.545 +    enum ParameterMode {PARAM_IN, PARAM_OUT, PARAM_INOUT};
   1.546 +    struct ParameterDescription {
   1.547 +	Identifier name;
   1.548 +	TypeCode type;
   1.549 +	IDLType type_def;
   1.550 +	ParameterMode mode;
   1.551 +    };
   1.552 +    typedef sequence <ParameterDescription> ParDescriptionSeq;
   1.553 +
   1.554 +    typedef Identifier ContextIdentifier;
   1.555 +    typedef sequence <ContextIdentifier> ContextIdSeq;
   1.556 +
   1.557 +    typedef sequence <ExceptionDef> ExceptionDefSeq;
   1.558 +    typedef sequence <ExceptionDescription> ExcDescriptionSeq;
   1.559 +
   1.560 +    interface OperationDef : Contained
   1.561 +    /**
   1.562 +      An OperationDef represents the information that defines an
   1.563 +      operation of an interface.
   1.564 +     */
   1.565 +    {
   1.566 +	readonly attribute TypeCode result;
   1.567 +	attribute IDLType result_def;
   1.568 +	attribute ParDescriptionSeq params;
   1.569 +	attribute OperationMode mode;
   1.570 +	attribute ContextIdSeq contexts;
   1.571 +	attribute ExceptionDefSeq exceptions;
   1.572 +    };
   1.573 +
   1.574 +    struct OperationDescription {
   1.575 +	Identifier name;
   1.576 +	RepositoryId id;
   1.577 +	RepositoryId defined_in;
   1.578 +	VersionSpec version;
   1.579 +	TypeCode result;
   1.580 +	OperationMode mode;
   1.581 +	ContextIdSeq contexts;
   1.582 +	ParDescriptionSeq parameters;
   1.583 +	ExcDescriptionSeq exceptions;
   1.584 +    };
   1.585 +
   1.586 +
   1.587 +
   1.588 +    typedef sequence <RepositoryId> RepositoryIdSeq;
   1.589 +    typedef sequence <OperationDescription> OpDescriptionSeq;
   1.590 +    typedef sequence <AttributeDescription> AttrDescriptionSeq;
   1.591 +
   1.592 +    interface InterfaceDef : Container, Contained, IDLType
   1.593 +    /**
   1.594 +      An InterfaceDef object represents an interface definition. It can
   1.595 +      contains constants, typedefs, exceptions, operations, and
   1.596 +      attributes.
   1.597 +     */
   1.598 +    {
   1.599 +	// read/write interface
   1.600 +
   1.601 +	attribute InterfaceDefSeq base_interfaces;
   1.602 +	attribute boolean is_abstract;
   1.603 +
   1.604 +	// read interface
   1.605 +
   1.606 +	boolean is_a (in RepositoryId interface_id);
   1.607 +
   1.608 +	struct FullInterfaceDescription {
   1.609 +	    Identifier name;
   1.610 +	    RepositoryId id;
   1.611 +	    RepositoryId defined_in;
   1.612 +	    VersionSpec version;
   1.613 +	    boolean is_abstract;
   1.614 +	    OpDescriptionSeq operations;
   1.615 +	    AttrDescriptionSeq attributes;
   1.616 +	    RepositoryIdSeq base_interfaces;
   1.617 +	    TypeCode type;
   1.618 +	};
   1.619 +
   1.620 +	FullInterfaceDescription describe_interface();
   1.621 +
   1.622 +	// write interface
   1.623 +
   1.624 +	AttributeDef create_attribute (
   1.625 +	    in RepositoryId id,
   1.626 +	    in Identifier name,
   1.627 +	    in VersionSpec version,
   1.628 +	    in IDLType type,
   1.629 +	    in AttributeMode mode
   1.630 +	    );
   1.631 +
   1.632 +	OperationDef create_operation (
   1.633 +	    in RepositoryId id,
   1.634 +	    in Identifier name,
   1.635 +	    in VersionSpec version,
   1.636 +	    in IDLType result,
   1.637 +	    in OperationMode mode,
   1.638 +	    in ParDescriptionSeq params,
   1.639 +	    in ExceptionDefSeq exceptions,
   1.640 +	    in ContextIdSeq contexts
   1.641 +	    );
   1.642 +    };
   1.643 +
   1.644 +    struct InterfaceDescription {
   1.645 +	Identifier name;
   1.646 +	RepositoryId id;
   1.647 +	RepositoryId defined_in;
   1.648 +	VersionSpec version;
   1.649 +	RepositoryIdSeq base_interfaces;
   1.650 +    };
   1.651 +
   1.652 +
   1.653 +    // orbos 98-01-18: Objects By Value -- begin
   1.654 +
   1.655 +    interface ValueMemberDef : Contained
   1.656 +
   1.657 +      /** A <code>ValueMemberDef</code> object represents the public
   1.658 +      and private data member definition of a <code>Value</code> type
   1.659 +      */
   1.660 +
   1.661 + {
   1.662 +        readonly attribute TypeCode type;
   1.663 +	         attribute IDLType type_def;
   1.664 +		 attribute Visibility access;
   1.665 +    };
   1.666 +
   1.667 +    interface ValueDef : Container, Contained, IDLType
   1.668 +      /**
   1.669 +	A ValueDef object represents the definition of the
   1.670 +	<code>Value</code> object used to pass the object state
   1.671 +	between hosts
   1.672 +	*/
   1.673 +
   1.674 +      {
   1.675 +	   // read/write interface
   1.676 +	    attribute InterfaceDefSeq supported_interfaces;
   1.677 +	    attribute InitializerSeq initializers;
   1.678 +	    attribute ValueDef base_value;
   1.679 +	    attribute ValueDefSeq abstract_base_values;
   1.680 +	    attribute boolean is_abstract;
   1.681 +	    attribute boolean is_custom;
   1.682 +	    attribute octet flags; // always 0
   1.683 +	    attribute boolean has_safe_base;
   1.684 +
   1.685 +	    // read interface
   1.686 +	    boolean is_a(in RepositoryId value_id);
   1.687 +
   1.688 +	    struct FullValueDescription {
   1.689 +	      Identifier 	name;
   1.690 +	      RepositoryId 	id;
   1.691 +	      boolean 	is_abstract;
   1.692 +	      boolean 	is_custom;
   1.693 +	      octet 		flags; // always 0
   1.694 +	      RepositoryId 	defined_in;
   1.695 +	      VersionSpec 	version;
   1.696 +	      OpDescriptionSeq operations;
   1.697 +	      AttrDescriptionSeq attributes;
   1.698 +	      ValueMemberSeq 	members;
   1.699 +	      InitializerSeq 	initializers;
   1.700 +	      RepositoryIdSeq supported_interfaces;
   1.701 +	      RepositoryIdSeq abstract_base_values;
   1.702 +	      boolean 	has_safe_base;
   1.703 +	      RepositoryId	base_value;
   1.704 +	      TypeCode	type;
   1.705 +	  };
   1.706 +
   1.707 +	  FullValueDescription describe_value();
   1.708 +
   1.709 +	  // write interface
   1.710 +
   1.711 +	  ValueMemberDef create_value_member(
   1.712 +	      in RepositoryId id,
   1.713 +	      in Identifier name,
   1.714 +	      in VersionSpec version,
   1.715 +	      in IDLType type_def,
   1.716 +	      in Visibility access
   1.717 +	  );
   1.718 +
   1.719 +	  AttributeDef create_attribute(
   1.720 +	      in RepositoryId id,
   1.721 +	      in Identifier   name,
   1.722 +	      in VersionSpec  version,
   1.723 +	      in IDLType      type,
   1.724 +	      in AttributeMode mode
   1.725 +	  );
   1.726 +
   1.727 +	  OperationDef create_operation(
   1.728 +	      in RepositoryId id,
   1.729 +	      in Identifier   name,
   1.730 +	      in VersionSpec  version,
   1.731 +	      in IDLType      result,
   1.732 +	      in OperationMode     mode,
   1.733 +	      in ParDescriptionSeq params,
   1.734 +	      in ExceptionDefSeq   exceptions,
   1.735 +	      in ContextIdSeq contexts
   1.736 +	  );
   1.737 +    };
   1.738 +    struct ValueDescription {
   1.739 +        Identifier name;
   1.740 +        RepositoryId id;
   1.741 +        boolean is_abstract;
   1.742 +        boolean is_custom;
   1.743 +        octet   flags; // always 0
   1.744 +        RepositoryId defined_in;
   1.745 +        VersionSpec version;
   1.746 +        RepositoryIdSeq supported_interfaces;
   1.747 +        RepositoryIdSeq abstract_base_values;
   1.748 +        boolean has_safe_base;
   1.749 +        RepositoryId base_value;
   1.750 +    };
   1.751 +
   1.752 +    interface ValueBoxDef : IDLType 
   1.753 +
   1.754 +      /** ValueBoxDef is an interface that reresents a value type with
   1.755 +	a single data member inside its state section and no
   1.756 +	inheritance or methods. For example, when transmitting a
   1.757 +	string or sequence as an actual parameter on an interface
   1.758 +	operation or as a data member of a value type that is an
   1.759 +	actual parameter, it may be important to preserve any sharing
   1.760 +	of the string or sequence within the object graph being
   1.761 +	transmitted. Because current IDL data types do not preserve
   1.762 +	referential integrity in this way, this requirement is
   1.763 +	conveniently handled by using a value type. Value types also
   1.764 +	support the transmission of nulls (as a distinguished value),
   1.765 +	whereas IDL data types such as string and sequence (which are
   1.766 +	mapped to empty strings and sequences) do not. The Java to IDL
   1.767 +	mapping requires both preservation of referential integrity
   1.768 +	and transmission of nulls. Because it would be cumbersome to
   1.769 +	require the full IDL syntax for a value type for this specific
   1.770 +	usage, this shorthand notation is introduced to cover this use
   1.771 +	of value types for simple containment of a single data member.
   1.772 +	*/
   1.773 +
   1.774 +    {
   1.775 +        attribute IDLType original_type_def;
   1.776 +    };
   1.777 +    
   1.778 +    // orbos 98-01-18: Objects By Value -- end
   1.779 +
   1.780 +    enum TCKind {
   1.781 +        tk_null, tk_void,
   1.782 +        tk_short, tk_long, tk_ushort, tk_ulong,
   1.783 +        tk_float, tk_double, tk_boolean, tk_char,
   1.784 +        tk_octet, tk_any, tk_TypeCode, tk_Principal, tk_objref,
   1.785 +        tk_struct, tk_union, tk_enum, tk_string,
   1.786 +        tk_sequence, tk_array, tk_alias, tk_except,
   1.787 +        tk_longlong, tk_ulonglong, tk_longdouble,
   1.788 +        tk_wchar, tk_wstring, tk_fixed,
   1.789 +        tk_value, tk_value_box,
   1.790 +        tk_native,
   1.791 +        tk_abstract_interface
   1.792 +    };
   1.793 +
   1.794 +    interface NativeDef : TypedefDef {
   1.795 +    };
   1.796 +};

mercurial