// some types used for testing #ifndef _RDITestTypes_IDL_ #define _RDITestTypes_IDL_ // omniORB specific pragmas to insert extra includes into the stub header. #pragma hh #include "COS_sysdep.h" #pragma prefix "research.att.com" #ifdef _IDL_TO_JAVA #pragma javaPackage "com.att.research" #endif module RDITestTypes { typedef string StringArrayFive[5]; typedef string StringArrayTen[10]; enum UnionSwitch { a, b, c, d, e}; union UnionType switch (UnionSwitch) { case a: long aLong; case b: string bString; case c: short cShort; case d: StringArrayFive dArray; default: boolean defaultBoolean; }; typedef sequence StringSeq; typedef sequence DoubleSeq; union ExampleUnion1 switch(boolean) { case TRUE: long l; default: double d; }; union ExampleUnion2 switch(long) { case 1: long l; case 2: double d; }; union ExampleUnion3 switch(boolean) { case TRUE: long l; case FALSE: double d; }; #if 0 // this idl is not legal ? union ExampleUnion4 switch(short) { case 0: case 2: string s; case 3: long l; case 5: double d; default: unsigned short u; }; #endif // no 'special' fieldd struct StructExample1 { double d; }; // this has an event_name member struct StructExample2 { string event_name; double d; }; // this has domain_name, type_name, // and filterable_data members, where // the filterable_data is not of the usual type struct StructExample3 { string domain_name; string type_name; string filterable_data; double d; }; // a struct containing structs struct StructExample4 { StructExample1 part1; StructExample2 part2; StructExample3 part3; }; }; #endif