@Override public boolean supports( MethodParameter returnType, Class<? extends HttpMessageConverter<?>> converterType) { Class<?> controllerType = returnType.getDeclaringClass(); return !HalJsonMvcEndpoint.class.isAssignableFrom(controllerType); }
/** * Class which declares the method to which this input parameter belongs. * * @return class */ public Class<?> getDeclaringClass() { return methodParameter.getDeclaringClass(); }