User`s manual
Passing Data to a Java Method
5-47
scalar (1-by-1) arrays or matrices. All of the Java types can be scalar values or
arrays.
Data type conversion of arguments passed to Java code will be discussed in the
following three categories. MATLAB handles each category differently.
•“Passing Built-In Data Types”
•“Passing String Arguments”
•“Passing Java Objects”
Table 5-2: Conversion of MATLAB Types to Java Types
MATLAB
Argument
Closest
Type (7)
Java Input Argument (Scalar or Array) Least Close
Type (1)
double
(logical)
boolean byte short int long float double
double double float long int short byte boolean
single float double
char String char
uint8 byte short int long float double
uint16 short int long float double
uint32 int long float double
int8 byte short int long float double
int16 short int long float double
int32 int long float double
cell array
of strings
array of
String
Java object Object
cell array
of object
array of
Object