The WebSphere CORBA valuetype library for C++ provides mappings for the following primitive data types:
Java | IDL Type | C++ Type |
---|---|---|
boolean | boolean | CORBA::Boolean |
byte | octet | CORBA::Octet |
char | wchar | CORBA::Wchar |
double | double | CORBA::Double |
float | float | CORBA::Float |
int | long | CORBA::Long |
int | unsigned long | CORBA::ULong |
long | long long | CORBA::LongLong |
long | unsigned long long | CORBA::ULongLong |
byte | char | CORBA::Char |
short | short | CORBA::Short |
short | unsigned short | CORBA::UShort |
void | void | CORBA::void |
Objects behave somewhat differently, as shown in the following examples (Java type-> IDL type-> C++ type):
byte[]-> ::org::omg::boxedRMI::seq1_octet-> ::org::omg::boxedRMI::seq1_octet*
java.lang.String-> ::CORBA::WstringValue-> ::CORBA::WstringValue*
Java.util.Enumeration-> abstract valuetype Enumeration-> ::java::util:: Enumeration
The IDL definition for the Enumeration valuetype (as generated by the rmic -idl utility) is as follows:
module java { module util { abstract valuetype Enumeration; }; };