# Uses of Class
io.dapr.utils.TypeRef

Packages that use TypeRef
Package
Description
io.dapr.actors.client
io.dapr.actors.runtime
io.dapr.client
io.dapr.exceptions
io.dapr.serializer
io.dapr.utils

## Uses of TypeRef in io.dapr.actors.client

Methods in io.dapr.actors.client with parameters of type TypeRef
Modifier and Type
Method
Description
`<T> reactor.core.publisher.Mono<T>`
ActorProxy.`invokeMethod(String methodName, TypeRef<T> type)`
Invokes an Actor method on Dapr.
`<T> reactor.core.publisher.Mono<T>`
ActorProxy.`invokeMethod(String methodName, Object data, TypeRef<T> type)`
Invokes an Actor method on Dapr.

## Uses of TypeRef in io.dapr.actors.runtime

Methods in io.dapr.actors.runtime that return TypeRef
Modifier and Type
Method
Description
`TypeRef<T>`
Remindable.`getStateType()`
Gets the type for state object.
Methods in io.dapr.actors.runtime with parameters of type TypeRef
Modifier and Type
Method
Description
`<T> reactor.core.publisher.Mono<T>`
ActorStateManager.`get(String stateName, TypeRef<T> type)`
Fetches the most recent value for the given state, including cached value.

## Uses of TypeRef in io.dapr.client

Methods in io.dapr.client with parameters of type TypeRef
Modifier and Type
Method
Description
`<T> T`
ObjectSerializer.`deserialize(byte[] content, TypeRef<T> type)`
Deserializes the byte array into the original object.
`<T> reactor.core.publisher.Mono<List<State<T>>>`
DaprClient.`getBulkState(GetBulkStateRequest request, TypeRef<T> type)`
Retrieve bulk States based on their keys.
`<T> reactor.core.publisher.Mono<List<State<T>>>`
DaprClient.`getBulkState(String storeName, List<String> keys, TypeRef<T> type)`
Retrieve bulk States based on their keys.
`<T> reactor.core.publisher.Mono<List<State<T>>>`
DaprClientImpl.`getBulkState(GetBulkStateRequest request, TypeRef<T> type)`
Retrieve bulk States based on their keys.
`<T> reactor.core.publisher.Mono<State<T>>`
DaprClient.`getState(GetStateRequest request, TypeRef<T> type)`
Retrieve a State based on their key.
`<T> reactor.core.publisher.Mono<State<T>>`
DaprClient.`getState(String storeName, State<T> state, TypeRef<T> type)`
Retrieve a State based on their key.
`<T> reactor.core.publisher.Mono<State<T>>`
DaprClient.`getState(String storeName, String key, StateOptions options, TypeRef<T> type)`
Retrieve a State based on their key.
`<T> reactor.core.publisher.Mono<State<T>>`
DaprClient.`getState(String storeName, String key, TypeRef<T> type)`
Retrieve a State based on their key.
`<T> reactor.core.publisher.Mono<State<T>>`
DaprClientImpl.`getState(GetStateRequest request, TypeRef<T> type)`
Retrieve a State based on their key.
`<T> reactor.core.publisher.Mono<T>`
DaprClient.`invokeBinding(InvokeBindingRequest request, TypeRef<T> type)`
Invokes a Binding operation.
`<T> reactor.core.publisher.Mono<T>`
DaprClient.`invokeBinding(String bindingName, String operation, Object data, TypeRef<T> type)`
Invokes a Binding operation.
`<T> reactor.core.publisher.Mono<T>`
DaprClient.`invokeBinding(String bindingName, String operation, Object data, Map<String,String> metadata, TypeRef<T> type)`
Invokes a Binding operation.
`<T> reactor.core.publisher.Mono<T>`
DaprClientImpl.`invokeBinding(InvokeBindingRequest request, TypeRef<T> type)`
Invokes a Binding operation.
`<T> reactor.core.publisher.Mono<T>`
DaprClient.`invokeMethod(InvokeMethodRequest invokeMethodRequest, TypeRef<T> type)`
Invoke a service method.
`<T> reactor.core.publisher.Mono<T>`
DaprClient.`invokeMethod(String appId, String methodName, HttpExtension httpExtension, Map<String,String> metadata, TypeRef<T> type)`
Invoke a service method, using serialization.
`<T> reactor.core.publisher.Mono<T>`
DaprClient.`invokeMethod(String appId, String methodName, Object request, HttpExtension httpExtension, TypeRef<T> type)`
Invoke a service method, using serialization.
`<T> reactor.core.publisher.Mono<T>`
DaprClient.`invokeMethod(String appId, String methodName, Object data, HttpExtension httpExtension, Map<String,String> metadata, TypeRef<T> type)`
Invoke a service method, using serialization.
`<T> reactor.core.publisher.Mono<T>`
DaprClientImpl.`invokeMethod(InvokeMethodRequest invokeMethodRequest, TypeRef<T> type)`
`<T> reactor.core.publisher.Mono<QueryStateResponse<T>>`
DaprClientImpl.`queryState(QueryStateRequest request, TypeRef<T> type)`
Query for states using a query request.
`<T> reactor.core.publisher.Mono<QueryStateResponse<T>>`
DaprPreviewClient.`queryState(QueryStateRequest request, TypeRef<T> type)`
Query for states using a query request.
`<T> reactor.core.publisher.Mono<QueryStateResponse<T>>`
DaprPreviewClient.`queryState(String storeName, Query query, TypeRef<T> type)`
Query for states using a query domain object.
`<T> reactor.core.publisher.Mono<QueryStateResponse<T>>`
DaprPreviewClient.`queryState(String storeName, Query query, Map<String,String> metadata, TypeRef<T> type)`
Query for states using a query domain object.
`<T> reactor.core.publisher.Mono<QueryStateResponse<T>>`
DaprPreviewClient.`queryState(String storeName, String query, TypeRef<T> type)`
Query for states using a query string.
`<T> reactor.core.publisher.Mono<QueryStateResponse<T>>`
DaprPreviewClient.`queryState(String storeName, String query, Map<String,String> metadata, TypeRef<T> type)`
Query for states using a query string.
`<T> Subscription`
DaprClientImpl.`subscribeToEvents(String pubsubName, String topic, SubscriptionListener<T> listener, TypeRef<T> type)`
Subscribe to pubsub via streaming.
`<T> Subscription`
DaprPreviewClient.`subscribeToEvents(String pubsubName, String topic, SubscriptionListener<T> listener, TypeRef<T> type)`
Subscribe to pubsub via streaming.

## Uses of TypeRef in io.dapr.exceptions

Methods in io.dapr.exceptions with parameters of type TypeRef
Modifier and Type
Method
Description
`<T> T`
DaprErrorDetails.`get(DaprErrorDetails.ErrorDetailType errorDetailType, String errAttribute, TypeRef<T> typeRef)`
Gets an attribute of an error detail.

## Uses of TypeRef in io.dapr.serializer

Methods in io.dapr.serializer with parameters of type TypeRef
Modifier and Type
Method
Description
`<T> T`
DaprObjectSerializer.`deserialize(byte[] data, TypeRef<T> type)`
Deserializes the given byte[] into a object.
`<T> T`
DefaultObjectSerializer.`deserialize(byte[] data, TypeRef<T> type)`
Deserializes the byte array into the original object.

## Uses of TypeRef in io.dapr.utils

Fields in io.dapr.utils declared as TypeRef
Modifier and Type
Field
Description
`static final TypeRef<Boolean>`
TypeRef.`BOOLEAN`
`static final TypeRef<Byte>`
TypeRef.`BYTE`
`static final TypeRef<byte[]>`
TypeRef.`BYTE_ARRAY`
`static final TypeRef<Character>`
TypeRef.`CHAR`
`static final TypeRef<Double>`
TypeRef.`DOUBLE`
`static final TypeRef<Float>`
TypeRef.`FLOAT`
`static final TypeRef<Integer>`
TypeRef.`INT`
`static final TypeRef<int[]>`
TypeRef.`INT_ARRAY`
`static final TypeRef<Long>`
TypeRef.`LONG`
`static final TypeRef<Short>`
TypeRef.`SHORT`
`static final TypeRef<String>`
TypeRef.`STRING`
`static final TypeRef<String[]>`
TypeRef.`STRING_ARRAY`
`static final TypeRef<Void>`
TypeRef.`VOID`
Methods in io.dapr.utils that return TypeRef
Modifier and Type
Method
Description
`static <T> TypeRef<T>`
TypeRef.`get(Class<T> clazz)`
Creates a reference to a given class type.
`static <T> TypeRef<T>`
TypeRef.`get(Type type)`
Creates a reference to a given class type.
Methods in io.dapr.utils with parameters of type TypeRef
Modifier and Type
Method
Description
`static <T> T`
DefaultContentTypeConverter.`convertBytesToEventFromGrpc(byte[] event, String contentType, TypeRef<T> typeRef)`
Function to convert a bytes array from gRPC input into event based on given object deserializer.
`static <T> T`
DefaultContentTypeConverter.`convertBytesToEventFromHttp(byte[] event, String contentType, TypeRef<T> typeRef)`
Function to convert a bytes array from HTTP input into event based on given object deserializer.
`static <T> boolean`
TypeRef.`isPrimitive(TypeRef<T> typeRef)`
Checks if the given TypeRef is of a primitive type Similar to implementation of deserializePrimitives in the class `ObjectSerializer` It considers only those types as primitives.