Skip to main content

Module type_map

Module type_map 

Source
Expand description

Mapping of IDL primitives to Java type strings.

Follows OMG IDL4-Java-Mapping v1.0 §6 (Type Mapping). Java has no native unsigned integer types — the spec-conformant workaround:

  • unsigned short → Java int (not short, to cover the full value range).
  • unsigned long → Java long (not int).
  • unsigned long long → Java long (with doc note; the default is the long variant; BigInteger would be the full solution, but is outside the current scope).

booleanboolean, octetbyte, char/wcharchar, string/wstringString, float/doublefloat/double.

Functions§

floating_to_java
Mapping from floating-point subtypes. long double is outside the current scope and is handled in typespec_to_java as crate::error::JavaGenError::UnsupportedConstruct.
floating_to_java_boxed
Boxed variant for floating-point subtypes.
integer_to_java
Mapping from integer subtypes.
integer_to_java_boxed
Boxed variant for integer subtypes.
is_unsigned
Returns true if an IDL integer type requires the Java unsigned workaround (doc note in the generator).
primitive_to_java
Mapping from a PrimitiveType to its Java type.
primitive_to_java_boxed
Boxed wrapper class for a primitive Java type, used for generics (e.g. List<Integer> instead of List<int>).