//#
//#  COMPONENT_NAME: somi
//#
//#  ORIGINS: 27
//#
//#
//#    25H7912  (C)   COPYRIGHT International Business Machines Corp. 1992,1994,1996,1996  
//#  All Rights Reserved
//#  Licensed Materials - Property of IBM
//#  US Government Users Restricted Rights - Use, duplication or
//#  disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
//#
//#  @(#) 2.9.1.4 src/somi/ir/somir/intfacdf.idl, somi.corba, som3.0 1/3/96 14:29:07 [12/22/96 21:12:31]


//#  InterfaceDef: CORBA Interface for interface definitions
//#  See CORBA 1.1, 7.5.4, p.134

#ifndef intfacdf_idl
#define intfacdf_idl

#include <containd.idl>
#include <containr.idl>
#include <somcls.idl>
#include <attribdf.idl>
#include <operatdf.idl>


interface InterfaceDef : Contained , Container
// This interface is used to access information associated with
// interfaces defined in an IDL file.
//
// See CORBA 1.1, 7.5.4, p.134
{
    struct FullInterfaceDescription {
	Identifier   name;
	RepositoryId id;
	RepositoryId defined_in;
	sequence<OperationDef::OperationDescription> operation;
	sequence<AttributeDef::AttributeDescription> attributes;
    };
    struct InterfaceDescription {
	Identifier   name;
	RepositoryId id;
	RepositoryId defined_in;
    };
    // The inherited describe method returns an instance of this
    // (InterfaceDescription) structure in the "value" member of the
    // Description structure defined in the Contained interface.
    // The inherited describe_contents method in the Container
    // interface returns a sequence of these Description structures
    // each carrying a reference to an InterfaceDescription structure
    // in its "value" member.

    attribute sequence<RepositoryId> base_interfaces;
    // The sequence of RepositoryIds for all of the interfaces that the
    // receiving interface inherits.  Do not free the buffer,
    // its storage is still owned by the InterfaceDef object.

    FullInterfaceDescription describe_interface();
    // Returns a description of all the operations and attributes in
    // an interface.

    attribute TypeCode instanceData;
    // [SOM-unique extension]
    //
    // The instance data members (if any) described in the SOM
    // implementation section of the IDL source file.

#ifdef __SOMIDL__
  implementation {
      releaseorder: describe_interface,
		  _get_base_interfaces, _set_base_interfaces,
		  _get_instanceData, _set_instanceData
		  ;

      //# Class Modifiers
      callstyle = idl;
      majorversion = 2;
      minorversion = 3;
      filestem = intfacdf;
      dllname = "somir.dll";

      passthru C_h =
	""
	"    #include <somtcnst.h>"
	"    #include <somir.h>"
	"    #include <operatdf.h>"
	"    #include <attribdf.h>"
	"";
      passthru C_xh =
	""
	"    #include <somtcnst.xh>"
	"    #include <somir.xh>"
	"    #include <operatdf.xh>"
	"    #include <attribdf.xh>"
	"";

      //# Attribute Modifiers
      base_interfaces: noset;
      instanceData: noset;
#if defined __SOM_KERNEL_LEVEL && __SOM_KERNEL_LEVEL >= 250
      _get_base_interfaces : dual_owned_result;
      _get_instanceData : dual_owned_result;
#else
      _set_base_interfaces : caller_owns_parameters = "base_interfaces";
      _set_instanceData : caller_owns_parameters = "instanceData";
#endif

      //# Method Modifiers
      somDefaultInit: override, init;
      somDestruct: override;
      somDumpSelf: override;
      somDumpSelfInt: override;
      within: override;
      describe: override;
#if defined __SOM_KERNEL_LEVEL && __SOM_KERNEL_LEVEL >= 250
      describe_interface: dual_owned_result;
#endif

  };
#endif /* __SOMIDL__ */
};

#endif	/* intfacdf_idl */
