inline fun <reified T : Any> RequestBodySpec.bodyWithType(producer: Any): RequestHeadersSpec<*>
Extension for RequestBodySpec.body providing a bodyWithType<T>(Any)
variant
leveraging Kotlin reified type parameters. This extension is not subject to type
erasure and retains actual generic type arguments.
producer
- the producer to write to the request. This must be a
Publisher or another producer adaptable to a
Publisher via org.springframework.core.ReactiveAdapterRegistry
Parameters
Author
Sebastien Deleuze
Since
5.2
inline fun <reified T : Any> RequestBodySpec.bodyWithType(publisher: Publisher<T>): RequestHeadersSpec<*>
Extension for RequestBodySpec.body providing a bodyWithType(Publisher<T>)
variant
leveraging Kotlin reified type parameters. This extension is not subject to type
erasure and retains actual generic type arguments.
publisher
- the Publisher to write to the request
Parameters
Author
Sebastien Deleuze
Since
5.2
@ExperimentalCoroutinesApi inline fun <reified T : Any> RequestBodySpec.bodyWithType(flow: Flow<T>): RequestHeadersSpec<*>
Extension for RequestBodySpec.body providing a bodyWithType(Flow<T>)
variant
leveraging Kotlin reified type parameters. This extension is not subject to type
erasure and retains actual generic type arguments.
flow
- the Flow to write to the request
Parameters
Author
Sebastien Deleuze
Since
5.2