diff --git a/org.springframework.web/src/main/java/org/springframework/web/client/RestTemplate.java b/org.springframework.web/src/main/java/org/springframework/web/client/RestTemplate.java index b1189b54a93..8e559003b0b 100644 --- a/org.springframework.web/src/main/java/org/springframework/web/client/RestTemplate.java +++ b/org.springframework.web/src/main/java/org/springframework/web/client/RestTemplate.java @@ -61,11 +61,11 @@ import org.springframework.web.util.UriTemplate; *
  * String result = restTemplate.getForObject("http://example.com/hotels/{hotel}/bookings/{booking}", String.class,"42", "21");
  * 
- * will perform a GET on {@code http://example.com/hotels/42/bookings/21}. The map variant is explands the template + * will perform a GET on {@code http://example.com/hotels/42/bookings/21}. The map variant expands the template * based on variable name, and is therefore more useful when using many variables, or when a single variable is used * multiple times. For example: *
- * Map<String, String> vars = Collections.singletonMap("hotel", 42);
+ * Map<String, String> vars = Collections.singletonMap("hotel", "42");
  * String result = restTemplate.getForObject("http://example.com/hotels/{hotel}/rooms/{hotel}", String.class, vars);
  * 
* will perform a GET on {@code http://example.com/hotels/42/rooms/42}. @@ -76,7 +76,7 @@ import org.springframework.web.util.UriTemplate; * bean property. * *

This template uses a {@link org.springframework.http.client.SimpleClientHttpRequestFactory} and a {@link - * DefaultResponseErrorHandler} as default strategies for for creating HTTP connections or handling HTTP errors, respectively. + * DefaultResponseErrorHandler} as default strategies for creating HTTP connections or handling HTTP errors, respectively. * These defaults can be overridden through the {@link #setRequestFactory(ClientHttpRequestFactory) requestFactory} and * {@link #setErrorHandler(ResponseErrorHandler) errorHandler} bean properties. *