T
- the type of the array (e.g. T = int[], or T = Rational[])public class MarshalQueryableArray<T> extends Object implements MarshalQueryable<T>
T
.
To marshal any T
to/from a native type, the marshaler for T to/from that native type
also has to exist.
T
can be either a T2[] where T2 is an object type, or a P[] where P is a
built-in primitive (e.g. int[], float[], etc).
Constructor and Description |
---|
MarshalQueryableArray() |
Modifier and Type | Method and Description |
---|---|
Marshaler<T> |
createMarshaler(TypeReference<T> managedType,
int nativeType)
Create a marshaler between the selected managed and native type.
|
boolean |
isTypeMappingSupported(TypeReference<T> managedType,
int nativeType)
Determine whether or not this query marshal is able to create a marshaler that will
support the managed type and native type mapping.
|
public Marshaler<T> createMarshaler(TypeReference<T> managedType, int nativeType)
MarshalQueryable
This marshaler instance is only good for that specific type mapping; and will refuse to map other managed types, other native types, or an other combination that isn't this exact one.
createMarshaler
in interface MarshalQueryable<T>
managedType
- a managed type referencenativeType
- the native type, e.g.
TYPE_BYTE
public boolean isTypeMappingSupported(TypeReference<T> managedType, int nativeType)
MarshalQueryable
If this returns true
, then a marshaler can be instantiated by
MarshalQueryable.createMarshaler(android.hardware.camera2.utils.TypeReference<T>, int)
that will marshal data to/from the native type
from/to the managed type.
Most marshalers are likely to only support one type map.
isTypeMappingSupported
in interface MarshalQueryable<T>