TimeoutParameterResolver

Parameter resolver for parameters of @ComponentTimeoutHandler and @GroupTimeoutHandler.

Needs to be implemented alongside a ParameterResolver subclass.

Use case - Supporting serializable objects

If you need to pass serializable objects to your components, you can instead use @SerializableTimeoutData and let it generate a resolver for you.

Parameters

T

Type of the implementation

R

Type of the returned resolved objects

Functions

Link copied to clipboard
open fun resolve(option: TimeoutOption, data: SerializedComponentData): R?

Returns a resolved object for this argument.

Link copied to clipboard
open suspend fun resolveSuspend(option: TimeoutOption, data: SerializedComponentData): R?

Returns a resolved object for this argument.

Link copied to clipboard
abstract fun serialize(obj: R): SerializedComponentData

Serializes an instance of the resolvable object.