if (actionResult == null && resultObject != null) {
Class resultType = resultObject.getClass();
if (resultType != String.class) {
// + still not found, read @RenderWith value if exist
RenderWith renderWith = resultObject.getClass().getAnnotation(RenderWith.class);
if (renderWith != null) {
actionResult = lookupAndRegisterIfMissing(renderWith.value());
}
if (actionResult == null) {
// + still not found, lookup for type
actionResult = typeResults.get(resultObject.getClass());