private class DefaultWebTestClient.DefaultTypeBodySpec extends java.lang.Object implements WebTestClient.TypeBodySpec
Modifier and Type | Field and Description |
---|---|
private ResolvableType |
elementType |
private DefaultWebTestClient.UndecodedExchangeResult |
result |
Constructor and Description |
---|
DefaultTypeBodySpec(DefaultWebTestClient.UndecodedExchangeResult result,
ResolvableType elementType) |
Modifier and Type | Method and Description |
---|---|
WebTestClient.ListBodySpec |
list()
Extract a list of representations from the response.
|
WebTestClient.ListBodySpec |
list(int count)
Extract a list of representations consuming the first N elements.
|
<T> FluxExchangeResult<T> |
returnResult()
Return request and response details for the exchange incluidng the
response body decoded as
Flux<T> where <T> is the
expected element type. |
WebTestClient.SingleValueBodySpec |
value()
Extract a single representations from the response.
|
private final DefaultWebTestClient.UndecodedExchangeResult result
private final ResolvableType elementType
public DefaultTypeBodySpec(DefaultWebTestClient.UndecodedExchangeResult result, ResolvableType elementType)
public WebTestClient.SingleValueBodySpec value()
WebTestClient.TypeBodySpec
value
in interface WebTestClient.TypeBodySpec
public WebTestClient.ListBodySpec list()
WebTestClient.TypeBodySpec
list
in interface WebTestClient.TypeBodySpec
public WebTestClient.ListBodySpec list(int count)
WebTestClient.TypeBodySpec
list
in interface WebTestClient.TypeBodySpec
public <T> FluxExchangeResult<T> returnResult()
WebTestClient.TypeBodySpec
Flux<T>
where <T>
is the
expected element type. The returned Flux
may for example be
verified with the Reactor StepVerifier
.returnResult
in interface WebTestClient.TypeBodySpec