Get Scalar
Convenience Methods
Declaration
scalar_type
get
Scalar_type
(
java.lang.String fieldName,
int fieldId)
throws TibrvExceptionscalar_type
getAs
Scalar_type
(
java.lang.String fieldName,
int fieldId)
throws TibrvException
Purpose
Get the value of a field as a scalar value.
Remarks
Each convenience method in this family retrieves a field and extracts its data. If the field’s type (as it exists) does not match the type of the convenience method, then the get
type
method throws an exception; in contrast, the getAs
type
method attempts to convert the data (see Decoding and Type Conversion, and Wire Format to Java Datatype Conversion Matrix). If conversion is not possible, the method throws an exception with status code TibrvStatus.CONVERSION_FAILED.
Parameter |
Description |
|
Get a field with this name. |
|
Get the field with this identifier. |
Method Name |
Field Type |
Java Type |
Type Description |
|
|
|
boolean |
|
|
|
32-bit floating point |
|
|
|
64-bit floating point |
|
|
|
8-bit integer |
|
|
|
16-bit integer |
|
|
|
32-bit integer |
|
|
|
64-bit integer |