|
30 | 30 | import org.springframework.core.ParameterizedTypeReference;
|
31 | 31 | import org.springframework.http.HttpHeaders;
|
32 | 32 | import org.springframework.http.HttpMethod;
|
33 |
| -import org.springframework.http.HttpRequest; |
34 | 33 | import org.springframework.lang.Nullable;
|
35 | 34 | import org.springframework.util.Assert;
|
36 | 35 | import org.springframework.util.CollectionUtils;
|
|
39 | 38 |
|
40 | 39 |
|
41 | 40 | /**
|
42 |
| - * Container for HTTP request values accumulated from an |
43 |
| - * {@link HttpRequest @HttpRequest}-annotated method and arguments passed to it. |
44 |
| - * This allows an {@link HttpClientAdapter} adapt these inputs as it sees fit |
45 |
| - * to the API of the underlying client. |
| 41 | + * Container for HTTP request values extracted from an |
| 42 | + * {@link org.springframework.web.service.annotation.HttpExchange @HttpExchange}-annotated |
| 43 | + * method and argument values passed to it. This is then given to |
| 44 | + * {@link HttpClientAdapter} to adapt to the underlying HTTP client. |
46 | 45 | *
|
47 | 46 | * @author Rossen Stoyanchev
|
48 | 47 | * @since 6.0
|
49 | 48 | */
|
50 |
| -public class HttpRequestDefinition { |
| 49 | +public class HttpRequestSpec { |
51 | 50 |
|
52 | 51 | private static final MultiValueMap<String, String> EMPTY_COOKIES_MAP =
|
53 | 52 | CollectionUtils.toMultiValueMap(Collections.emptyMap());
|
@@ -86,6 +85,10 @@ public class HttpRequestDefinition {
|
86 | 85 | private boolean complete;
|
87 | 86 |
|
88 | 87 |
|
| 88 | + public HttpRequestSpec() { |
| 89 | + } |
| 90 | + |
| 91 | + |
89 | 92 | public void setUri(URI uri) {
|
90 | 93 | checkComplete();
|
91 | 94 | this.uri = uri;
|
@@ -175,6 +178,8 @@ private void checkComplete() {
|
175 | 178 |
|
176 | 179 | void setComplete() {
|
177 | 180 |
|
| 181 | + this.complete = true; |
| 182 | + |
178 | 183 | this.uriVariables = (this.uriVariables != null ?
|
179 | 184 | Collections.unmodifiableMap(this.uriVariables) : Collections.emptyMap());
|
180 | 185 |
|
|
0 commit comments