// TypeCode //trimmed by M.Umezawa 1998 04/18 #ifndef _Identifier #define _Identifier typedef string Identifier; #endif #ifndef _RepositoryId #define _RepositoryId typedef string RepositoryId; #endif enum TCKind { tk_null, tk_void, tk_short, tk_long, tk_ushort, tk_ulong, tk_float, tk_double, tk_boolean, tk_char, tk_octet, tk_any, tk_TypeCode, tk_Principal, tk_objref, tk_struct, tk_union, tk_enum, tk_string, tk_sequence, tk_array, tk_alias, tk_except, tk_longlong, tk_ulonglong, tk_longdouble, tk_wchar, tk_wstring, tk_fixed }; interface TypeCode { exception Bounds {}; exception BadKind {}; // for all TypeCode kinds boolean equal (in TypeCode tc); TCKind kind (); // for tk_objref, tk_struct, tk_union, tk_enum, tk_alias, and tk_except RepositoryId id () raises (BadKind); // for tk_objref, tk_struct, tk_union, tk_enum, tk_alias, and tk_except Identifier name () raises (BadKind); // for tk_struct, tk_union, tk_enum, and tk_except unsigned long member_count () raises (BadKind); Identifier member_name (in unsigned long index) raises (BadKind, Bounds); // for tk_struct, tk_union, and tk_except TypeCode member_type (in unsigned long index) raises (BadKind, Bounds); // for tk_union any member_label (in unsigned long index) raises (BadKind, Bounds); TypeCode discriminator_type () raises (BadKind); long default_index () raises (BadKind); // for tk_string, tk_sequence, and tk_array unsigned long length () raises (BadKind); // for tk_sequence, tk_array, and tk_alias TypeCode content_type () raises (BadKind); // for tk_fixed unsigned short fixed_digits() raises (BadKind); short fixed_scale() raises(BadKind); // deprecated interface long param_count (); any parameter (in long index) raises (Bounds); };