Package io.dapr.client.domain
Class QueryStateItem<T>
java.lang.Object
io.dapr.client.domain.QueryStateItem<T>
-
Constructor Summary
ConstructorsConstructorDescriptionQueryStateItem(String key)
Create an immutable state reference to be retrieved or deleted.QueryStateItem(String key, String etag, String error)
Create an immutable state reference to be retrieved or deleted.QueryStateItem(String key, T value, String etag)
Create an immutable state. -
Method Summary
-
Constructor Details
-
QueryStateItem
Create an immutable state reference to be retrieved or deleted. This Constructor CAN be used anytime you need to retrieve or delete a state.- Parameters:
key
- - The key of the state
-
QueryStateItem
Create an immutable state reference to be retrieved or deleted. This Constructor CAN be used anytime you need to retrieve or delete a state.- Parameters:
key
- - The key of the stateetag
- - The etag of the state - Keep in mind that for some state stores (like redis) only numbers are supported.error
- - Error when fetching the state.
-
QueryStateItem
Create an immutable state. This Constructor CAN be used anytime you want the state to be saved.- Parameters:
key
- - The key of the state.value
- - The value of the state.etag
- - The etag of the state - for some state stores (like redis) only numbers are supported.
-
-
Method Details
-
getValue
Retrieves the Value of the state.- Returns:
- The value of the state
-
getKey
Retrieves the Key of the state.- Returns:
- The key of the state
-
getEtag
Retrieve the ETag of this state.- Returns:
- The etag of the state
-
getError
Retrieve the error for this state.- Returns:
- The error for this state.
-
equals
-
hashCode
public int hashCode() -
toString
-