for (Method interfaceMethod : methods) {
Method method = BridgeMethodResolver.findBridgedMethod(interfaceMethod);
Class<?> responseClazz = method.getReturnType();
RequestMapping requestMapping = AnnotationUtils.findAnnotation(method, RequestMapping.class);
RestRequestResource restRequestResource = AnnotationUtils.findAnnotation(method, RestRequestResource.class);
boolean export = (restRequestResource != null ? restRequestResource.export() : true);
// if the method declaring class is in the parent, get the return type from the service or converter (because of erasure)
if (!marshallingServiceClass.equals(method.getDeclaringClass())) {
String restRequestResourceMethodName = (restRequestResource != null ? restRequestResource.methodName() : null);
String methodName = (StringUtils.hasText(restRequestResourceMethodName) ? restRequestResourceMethodName : method.getName());
Class<?>[] paramTypes = method.getParameterTypes();
try {
Method serviceMethod = ReflectionUtils.findMethod(serviceClass, methodName, paramTypes);
responseClazz = serviceMethod.getReturnType();
} catch(IllegalStateException e) {
}
}
if (export) {
boolean relative = (restRequestResource != null ? restRequestResource.relative() : true);
// just get first param if more than one
StringBuilder uri = new StringBuilder();
if (relative) {