Introduce ResolvableType.toClass() shortcut

Issue: SPR-17086
This commit is contained in:
Juergen Hoeller
2018-07-25 14:15:19 +02:00
parent 31bfc1dc2b
commit fd8e4abe5d
26 changed files with 40 additions and 28 deletions

View File

@@ -89,7 +89,7 @@ public class ResponseEntityResultHandler extends AbstractMessageWriterResultHand
}
ReactiveAdapter adapter = getAdapter(result);
return adapter != null && !adapter.isNoValue() &&
isSupportedType(result.getReturnType().getGeneric().resolve(Object.class));
isSupportedType(result.getReturnType().getGeneric().toClass());
}
@Nullable

View File

@@ -157,7 +157,7 @@ public class ViewResolutionResultHandler extends HandlerResultHandlerSupport
if (adapter.isNoValue()) {
return true;
}
type = result.getReturnType().getGeneric().resolve(Object.class);
type = result.getReturnType().getGeneric().toClass();
}
return (type != null &&