Browse Source

Polishing

pull/961/head
Juergen Hoeller 10 years ago
parent
commit
8558cbc9bf
  1. 4
      spring-messaging/src/main/java/org/springframework/messaging/handler/annotation/support/DefaultMessageHandlerMethodFactory.java
  2. 10
      spring-web/src/main/java/org/springframework/web/client/RestClientResponseException.java

4
spring-messaging/src/main/java/org/springframework/messaging/handler/annotation/support/DefaultMessageHandlerMethodFactory.java

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
/*
* Copyright 2002-2015 the original author or authors.
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -144,7 +144,7 @@ public class DefaultMessageHandlerMethodFactory implements MessageHandlerMethodF @@ -144,7 +144,7 @@ public class DefaultMessageHandlerMethodFactory implements MessageHandlerMethodF
@Override
public InvocableHandlerMethod createInvocableHandlerMethod(Object bean, Method method) {
InvocableHandlerMethod handlerMethod = new InvocableHandlerMethod(bean, method);
handlerMethod.setMessageMethodArgumentResolvers(argumentResolvers);
handlerMethod.setMessageMethodArgumentResolvers(this.argumentResolvers);
return handlerMethod;
}

10
spring-web/src/main/java/org/springframework/web/client/RestClientResponseException.java

@ -48,9 +48,9 @@ public abstract class RestClientResponseException extends RestClientException { @@ -48,9 +48,9 @@ public abstract class RestClientResponseException extends RestClientException {
* Construct a new instance of with the given response data.
* @param statusCode the raw status code value
* @param statusText the status text
* @param responseHeaders the response headers, may be {@code null}
* @param responseBody the response body content, may be {@code null}
* @param responseCharset the response body charset, may be {@code null}
* @param responseHeaders the response headers (may be {@code null})
* @param responseBody the response body content (may be {@code null})
* @param responseCharset the response body charset (may be {@code null})
*/
public RestClientResponseException(String message, int statusCode, String statusText,
HttpHeaders responseHeaders, byte[] responseBody, Charset responseCharset) {
@ -59,8 +59,8 @@ public abstract class RestClientResponseException extends RestClientException { @@ -59,8 +59,8 @@ public abstract class RestClientResponseException extends RestClientException {
this.rawStatusCode = statusCode;
this.statusText = statusText;
this.responseHeaders = responseHeaders;
this.responseBody = responseBody != null ? responseBody : new byte[0];
this.responseCharset = responseCharset != null ? responseCharset.name() : DEFAULT_CHARSET;
this.responseBody = (responseBody != null ? responseBody : new byte[0]);
this.responseCharset = (responseCharset != null ? responseCharset.name() : DEFAULT_CHARSET);
}

Loading…
Cancel
Save