spring-framework / org.springframework.web.reactive.function.client

Package org.springframework.web.reactive.function.client

Functions

awaitBody

Non-nullable Coroutines variant of ClientResponse.bodyToMono.

suspend fun <T : Any> ClientResponse.awaitBody(): T

Coroutines variant of WebClient.ResponseSpec.bodyToMono.

suspend fun <T : Any> ResponseSpec.awaitBody(): T

awaitBodyOrNull

Nullable coroutines variant of ClientResponse.bodyToMono.

suspend fun <T : Any> ClientResponse.awaitBodyOrNull(): T?

awaitEntity

Coroutines variant of ClientResponse.toEntity.

suspend fun <T : Any> ClientResponse.awaitEntity(): ResponseEntity<T>

awaitEntityList

Coroutines variant of ClientResponse.toEntityList.

suspend fun <T : Any> ClientResponse.awaitEntityList(): ResponseEntity<List<T>>

awaitExchange

Coroutines variant of WebClient.RequestHeadersSpec.exchange.

suspend fun RequestHeadersSpec<out RequestHeadersSpec<*>>.awaitExchange(): ClientResponse

body

Extension for WebClient.RequestBodySpec.body providing a body(Publisher<T>) variant leveraging Kotlin reified type parameters. This extension is not subject to type erasure and retains actual generic type arguments.

fun <T : Any, S : Publisher<T>> RequestBodySpec.body(publisher: S): RequestHeadersSpec<*>

Extension for WebClient.RequestBodySpec.body providing a body(Flow<T>) variant leveraging Kotlin reified type parameters. This extension is not subject to type erasure and retains actual generic type arguments.

fun <T : Any> RequestBodySpec.body(flow: Flow<T>): RequestHeadersSpec<*>

Extension for WebClient.RequestBodySpec.body providing a body<T>(Any) variant leveraging Kotlin reified type parameters. This extension is not subject to type erasure and retains actual generic type arguments.

fun <T : Any> RequestBodySpec.body(producer: Any): RequestHeadersSpec<*>

bodyToFlow

Coroutines kotlinx.coroutines.flow.Flow based variant of ClientResponse.bodyToFlux.

fun <T : Any> ClientResponse.bodyToFlow(): Flow<T>

Coroutines kotlinx.coroutines.flow.Flow based variant of WebClient.ResponseSpec.bodyToFlux.

fun <T : Any> ResponseSpec.bodyToFlow(): Flow<T>

bodyToFlux

Extension for ClientResponse.bodyToFlux providing a bodyToFlux<Foo>() variant leveraging Kotlin reified type parameters. This extension is not subject to type erasure and retains actual generic type arguments.

fun <T : Any> ClientResponse.bodyToFlux(): Flux<T>

Extension for WebClient.ResponseSpec.bodyToFlux providing a bodyToFlux<Foo>() variant leveraging Kotlin reified type parameters. This extension is not subject to type erasure and retains actual generic type arguments.

fun <T : Any> ResponseSpec.bodyToFlux(): Flux<T>

bodyToMono

Extension for ClientResponse.bodyToMono providing a bodyToMono<Foo>() variant leveraging Kotlin reified type parameters. This extension is not subject to type erasure and retains actual generic type arguments.

fun <T : Any> ClientResponse.bodyToMono(): Mono<T>

Extension for WebClient.ResponseSpec.bodyToMono providing a bodyToMono<Foo>() variant leveraging Kotlin reified type parameters. This extension is not subject to type erasure and retains actual generic type arguments.

fun <T : Any> ResponseSpec.bodyToMono(): Mono<T>

toEntity

Extension for ClientResponse.toEntity providing a toEntity<Foo>() variant leveraging Kotlin reified type parameters. This extension is not subject to type erasure and retains actual generic type arguments.

fun <T : Any> ClientResponse.toEntity(): Mono<ResponseEntity<T>>

toEntityList

Extension for ClientResponse.toEntityList providing a bodyToEntityList<Foo>() variant leveraging Kotlin reified type parameters. This extension is not subject to type erasure and retains actual generic type arguments.

fun <T : Any> ClientResponse.toEntityList(): Mono<ResponseEntity<List<T>>>