接口 RSocketRequester.RequestSpec
- 封闭接口:
- RSocketRequester
public static interface RSocketRequester.RequestSpec extends RSocketRequester.MetadataSpec<RSocketRequester.RequestSpec>, RSocketRequester.RetrieveSpec
Spec to declare the input for an RSocket request.
方法概要
所有方法 实例方法 抽象方法 修饰符和类型 方法 说明 RSocketRequester.RetrieveSpec
data(Object data)
Provide payload data for the request.RSocketRequester.RetrieveSpec
data(Object producer, Class<?> elementClass)
Variant ofdata(Object)
that also accepts a hint for the types of values that will be produced.RSocketRequester.RetrieveSpec
data(Object producer, ParameterizedTypeReference<?> elementTypeRef)
Variant ofdata(Object, Class)
for when the type hint has to have a generic type.RSocketRequester.RequestSpec
metadata(Consumer<RSocketRequester.MetadataSpec<?>> configurer)
Append additional metadata entries through aConsumer
.从接口继承的方法 org.springframework.messaging.rsocket.RSocketRequester.MetadataSpec
metadata
从接口继承的方法 org.springframework.messaging.rsocket.RSocketRequester.RetrieveSpec
retrieveFlux, retrieveFlux, retrieveMono, retrieveMono, send
方法详细资料
metadata
RSocketRequester.RequestSpec metadata(Consumer<RSocketRequester.MetadataSpec<?>> configurer)
Append additional metadata entries through aConsumer
. This enables libraries such as Spring Security to provide shortcuts for applying a set of customizations.- 参数:
configurer
- the configurer to apply- 抛出:
IllegalArgumentException
- if not using composite metadata.
data
RSocketRequester.RetrieveSpec data(Object data)
Provide payload data for the request. This can be one of:- Concrete value
Publisher
of value(s)- Any other producer of value(s) that can be adapted to a
Publisher
viaReactiveAdapterRegistry
- 参数:
data
- the Object value for the payload data- 返回:
- spec to declare the expected response
data
RSocketRequester.RetrieveSpec data(Object producer, Class<?> elementClass)
Variant ofdata(Object)
that also accepts a hint for the types of values that will be produced. The class hint is used to find a compatibleEncoder
once, up front vs per value.- 参数:
producer
- the source of payload data value(s). This must be aPublisher
or another producer adaptable to aPublisher
viaReactiveAdapterRegistry
elementClass
- the type of values to be produced- 返回:
- spec to declare the expected response
data
RSocketRequester.RetrieveSpec data(Object producer, ParameterizedTypeReference<?> elementTypeRef)
Variant ofdata(Object, Class)
for when the type hint has to have a generic type. SeeParameterizedTypeReference
.- 参数:
producer
- the source of payload data value(s). This must be aPublisher
or another producer adaptable to aPublisher
viaReactiveAdapterRegistry
elementTypeRef
- the type of values to be produced- 返回:
- spec to declare the expected response