R
- The response type which will be matched against and converted topublic abstract class AbstractResponseType<R> extends Object implements ResponseType<R>
ResponseType
which contains
match functions for the majority of the Type
options available.
For single instance response types, a direct assignable to check will be performed. For multiple instances response
types, the match will be performed against the containing type of that array/collection/etc.
Proves useful for reuse among ResponseType implementations.Modifier and Type | Field and Description |
---|---|
protected Class<?> |
expectedResponseType |
MATCH, NO_MATCH
Modifier | Constructor and Description |
---|---|
protected |
AbstractResponseType(Class<?> expectedResponseType)
Instantiate a
ResponseType with the given
expectedResponseType as the type to be matched against and to which the query response should be
converted to, as is or as the contained type for an array/list/etc. |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
Class<?> |
getExpectedResponseType()
Gets actual response type or generic placeholder.
|
int |
hashCode() |
protected boolean |
isArray(Type responseType) |
protected boolean |
isArrayOfExpectedType(Type responseType) |
protected boolean |
isAssignableFrom(Type responseType) |
protected boolean |
isGenericArrayOfExpectedType(Type responseType) |
protected boolean |
isGenericArrayType(Type responseType) |
protected boolean |
isGenericAssignableFrom(Type responseType) |
protected boolean |
isIterableOfExpectedType(Type responseType) |
protected boolean |
isParameterizedType(Type responseType) |
protected boolean |
isParameterizedTypeOfExpectedType(Type responseType) |
protected boolean |
isPublisherOfExpectedType(Type responseType) |
protected boolean |
isStreamOfExpectedType(Type responseType) |
protected boolean |
isTypeVariable(Type responseType) |
protected boolean |
isWildcardType(Type responseType) |
protected boolean |
isWildcardTypeWithMatchingUpperBound(Type responseType) |
protected boolean |
projectReactorOnClassPath() |
protected Type |
unwrapIfTypeFuture(Type type)
Deprecated.
Use
ReflectionUtils.unwrapIfType(Type, Class[]) instead |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
convert, convertExceptional, forSerialization, matches, matchRank, responseMessagePayloadType
protected final Class<?> expectedResponseType
protected AbstractResponseType(Class<?> expectedResponseType)
ResponseType
with the given
expectedResponseType
as the type to be matched against and to which the query response should be
converted to, as is or as the contained type for an array/list/etc.expectedResponseType
- the response type which is expected to be matched against and to be returned, as is
or as the contained type for an array/list/etcpublic Class<?> getExpectedResponseType()
ResponseType
getExpectedResponseType
in interface ResponseType<R>
@Deprecated protected Type unwrapIfTypeFuture(Type type)
ReflectionUtils.unwrapIfType(Type, Class[])
insteadtype
is of type Future
.type
- to be unwrappedtype
is not of type Future
protected boolean isPublisherOfExpectedType(Type responseType)
protected boolean isIterableOfExpectedType(Type responseType)
protected boolean isStreamOfExpectedType(Type responseType)
protected boolean isParameterizedTypeOfExpectedType(Type responseType)
protected boolean isParameterizedType(Type responseType)
protected boolean isWildcardTypeWithMatchingUpperBound(Type responseType)
protected boolean isWildcardType(Type responseType)
protected boolean isArrayOfExpectedType(Type responseType)
protected boolean isArray(Type responseType)
protected boolean isGenericArrayOfExpectedType(Type responseType)
protected boolean isGenericArrayType(Type responseType)
protected boolean isGenericAssignableFrom(Type responseType)
protected boolean isTypeVariable(Type responseType)
protected boolean isAssignableFrom(Type responseType)
protected boolean projectReactorOnClassPath()
Copyright © 2010–2024. All rights reserved.