home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / som30tk.zip / som30os2.zip / include / sccommon.idl < prev    next >
Text File  |  1996-12-24  |  4KB  |  132 lines

  1. //
  2. //   COMPONENT_NAME: some
  3. //
  4. //   ORIGINS: 27
  5. //
  6. //
  7. //    25H7912  (C)  COPYRIGHT International Business Machines Corp. 1992,1994,1996 
  8. //   All Rights Reserved
  9. //   Licensed Materials - Property of IBM
  10. //   US Government Users Restricted Rights - Use, duplication or
  11. //   disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  12. //
  13. //#  @(#) somc/sccommon.idl 2.9 5/9/96 15:31:01 [12/24/96 07:39:44]
  14.  
  15. #ifndef sccommon_idl
  16. #define sccommon_idl
  17.  
  18. #include <scentry.idl>
  19. interface SOMTTypedefEntryC;
  20.  
  21. enum somtVisibilityT { somtInternalVE, somtPublicVE, somtPrivateVE };
  22. interface SOMTCommonEntryC : SOMTEntryC
  23.  
  24. // This class defines a number of methods and attributes that are
  25. // common to <SOMTMethodEntry>, <SOMTDataEntry>, and
  26. // <SOMTParameterEntry>.  No entries of this type will actually
  27. // be found in the entry graph, instead they will all be one of
  28. // the types mentioned above.
  29. // Exception: entries whose somtElementType is SOMTTypedefBE, which
  30. // represent a reference to a user-defined type, are instance of this class.
  31.  
  32. {
  33.  
  34.   readonly attribute SOMTEntryC somtTypeObj;
  35.  
  36.   // The object representing the base type of the entry.
  37.   // This does not include pointer stars or array declarators.
  38.  
  39.   readonly attribute string somtPtrs;
  40.  
  41.   // The string of stars associated with the entry's type.
  42.   // For example, an object of type "foo" would have somtPtrs = NULL,
  43.   // type "foo *" would have somtPtrs = "*", type
  44.   // "foo **" would have somtPtrs = "**", etc.
  45.  
  46.   readonly attribute string somtArrayDimsString;
  47.  
  48.   // Array dimensions in string form.
  49.  
  50.   unsigned long somtGetFirstArrayDimension();
  51.   // The first array dimension, for items of type array.
  52.   // Zero indicates that the item is not an array.
  53.  
  54.   unsigned long somtGetNextArrayDimension();
  55.   // The next array dimension, for items of type array,
  56.   // relative to the previous call to this method or to
  57.   // somtGetFirstArrayDimension.  Zero indicates no more dimensions.
  58.  
  59.   readonly attribute string somtSourceText;
  60.   
  61.   // The un-parsed source text for this entry, with leading and
  62.   // trailing white space removed.  For attribute/typedef declarators
  63.   // and for user-defined types, this attribute only provides the
  64.   // source text for the entry's name.  For methods, arguments, 
  65.   // and instance variables, however, this attribute provides the 
  66.   // full definition.
  67.  
  68.   readonly attribute string somtType;
  69.   
  70.   // The IDL type for this entry in string form. For methods this is the
  71.   // return type.  For data or parameters this is the type of the data
  72.   // item or parameter. For user-defined types, this is the type specification.
  73.   // It is of the form:   <typename><pointer-stars> <array-declarators>
  74.  
  75.   readonly attribute somtVisibilityT somtVisibility;
  76.   
  77.   // The visibility of this entry.  Note: the visibility of
  78.   // parameter entries will always be public, and methods can never be
  79.   // internal.
  80.  
  81.   boolean somtIsArray(out long size);
  82.   
  83.   // Returns 1 (true) if the type involves an array.  When the type
  84.   // involves an array then <size> is set to be the size of the
  85.   // array.
  86.  
  87.   boolean somtIsPointer();
  88.   
  89.   // Returns 1 (true) if the type involves a pointer, and 0 (false)
  90.   // otherwise
  91.  
  92.  
  93.  
  94. #ifdef __SOMIDL__
  95.   implementation {
  96.     releaseorder: _get_somtSourceText, _get_somtType, 
  97.                   _get_somtVisibility, somtIsArray, 
  98.                   somtIsPointer, somtIsArrayDominant, 
  99.                   _get_somtTypeObj, _get_somtPtrs, 
  100.                   _get_somtArrayDimsString, somtGetFirstArrayDimension, 
  101.                   somtGetNextArrayDimension;
  102.  
  103.  
  104.     //# Class Modifiers
  105.     majorversion = 2;
  106.     minorversion = 1;
  107.     filestem = sccommon;
  108. #ifdef _WIN32
  109.     dllname = "some.dll";
  110. #endif
  111.     callstyle = oidl;
  112.  
  113.     passthru C_h = "typedef enum somtVisibilityT { somtInternalVE, somtPublicVE, somtPrivateVE } somtVisibilityT;";
  114.     passthru C_xh = "typedef enum somtVisibilityT { somtInternalVE, somtPublicVE, somtPrivateVE } somtVisibilityT;";
  115.   
  116.     //# Method Modifiers
  117.     somDumpSelfInt: override;
  118.     somtSetSymbolsOnEntry: override;
  119.   
  120.     //# Attribute Modifiers
  121.     somtTypeObj: nodata;
  122.     somtPtrs: nodata;
  123.     somtArrayDimsString: nodata;
  124.     somtType: nodata;
  125.     somtVisibility: nodata;
  126.  
  127.  
  128.   };
  129. #endif /* __SOMIDL__ */
  130. };
  131. #endif  /* sccommon_idl */
  132.