@SuppressWarnings("deprecation") @Test public void uriStuffedIntoMethod() { thrown.expect(IllegalArgumentException.class); thrown.expectMessage("Invalid HTTP Method: /path?queryParam={queryParam}"); new RequestTemplate().method("/path?queryParam={queryParam}"); }
@Deprecated public RequestTemplate method(String method) { checkNotNull(method, "method"); try { this.method = HttpMethod.valueOf(method); } catch (IllegalArgumentException iae) { throw new IllegalArgumentException("Invalid HTTP Method: " + method); } return this; }
RequestTemplate implements Serializable { @Deprecated public RequestTemplate method(String method) { checkNotNull(method, "method"); try { this.method = HttpMethod.valueOf(method); } catch (IllegalArgumentException iae) { throw new IllegalArgumentException("Invalid HTTP Method: " + method); } return this; } }
RequestTemplate implements Serializable { @Deprecated public RequestTemplate method(String method) { checkNotNull(method, "method"); try { this.method = HttpMethod.valueOf(method); } catch (IllegalArgumentException iae) { throw new IllegalArgumentException("Invalid HTTP Method: " + method); } return this; } RequestTemplate(); private  RequestTemplate(String target,
      String fragment,
      UriTemplate uriTemplate,
      BodyTemplate bodyTemplate,
      HttpMethod method,
      Charset charset,
      Request.Body body,
      boolean decodeSlash,
      CollectionFormat collectionFormat,
      MethodMetadata methodMetadata,
      Target<?> feignTarget); @Deprecated  RequestTemplate(RequestTemplate toCopy); }
RequestTemplate implements Serializable { @Deprecated public RequestTemplate method(String method) { checkNotNull(method, "method"); try { this.method = HttpMethod.valueOf(method); } catch (IllegalArgumentException iae) { throw new IllegalArgumentException("Invalid HTTP Method: " + method); } return this; } RequestTemplate(); private  RequestTemplate(String target,
      String fragment,
      UriTemplate uriTemplate,
      BodyTemplate bodyTemplate,
      HttpMethod method,
      Charset charset,
      Request.Body body,
      boolean decodeSlash,
      CollectionFormat collectionFormat,
      MethodMetadata methodMetadata,
      Target<?> feignTarget); @Deprecated  RequestTemplate(RequestTemplate toCopy); static RequestTemplate from(RequestTemplate requestTemplate); RequestTemplate resolve(Map<String, ?> variables); Request request(); @Deprecated RequestTemplate method(String method); RequestTemplate method(HttpMethod method); String method(); RequestTemplate decodeSlash(boolean decodeSlash); boolean decodeSlash(); RequestTemplate collectionFormat(CollectionFormat collectionFormat); @SuppressWarnings("unused") CollectionFormat collectionFormat(); @Deprecated RequestTemplate append(CharSequence value); @SuppressWarnings("unused") @Deprecated RequestTemplate insert(int pos, CharSequence value); RequestTemplate uri(String uri); RequestTemplate uri(String uri, boolean append); RequestTemplate target(String target); String url(); String path(); List<String> variables(); RequestTemplate query(String name, String... values); RequestTemplate query(String name, Iterable<String> values); RequestTemplate query(String name,
                               Iterable<String> values,
                               CollectionFormat collectionFormat); @SuppressWarnings("unused") RequestTemplate queries(Map<String, Collection<String>> queries); Map<String, Collection<String>> queries(); RequestTemplate header(String name, String... values); RequestTemplate header(String name, Iterable<String> values); RequestTemplate removeHeader(String name); RequestTemplate headers(Map<String, Collection<String>> headers); Map<String, Collection<String>> headers(); RequestTemplate body(byte[] data, Charset charset); RequestTemplate body(String bodyText); @Deprecated RequestTemplate body(Request.Body body); Charset requestCharset(); byte[] body(); @Deprecated Request.Body requestBody(); RequestTemplate bodyTemplate(String bodyTemplate); RequestTemplate bodyTemplate(String bodyTemplate, Charset charset); String bodyTemplate(); @Override String toString(); boolean hasRequestVariable(String variable); Collection<String> getRequestVariables(); @SuppressWarnings("unused") boolean resolved(); String queryLine(); @Experimental RequestTemplate methodMetadata(MethodMetadata methodMetadata); @Experimental RequestTemplate feignTarget(Target<?> feignTarget); @Experimental MethodMetadata methodMetadata(); @Experimental Target<?> feignTarget(); }
RequestTemplate implements Serializable { @Deprecated public RequestTemplate method(String method) { checkNotNull(method, "method"); try { this.method = HttpMethod.valueOf(method); } catch (IllegalArgumentException iae) { throw new IllegalArgumentException("Invalid HTTP Method: " + method); } return this; } RequestTemplate(); private  RequestTemplate(String target,
      String fragment,
      UriTemplate uriTemplate,
      BodyTemplate bodyTemplate,
      HttpMethod method,
      Charset charset,
      Request.Body body,
      boolean decodeSlash,
      CollectionFormat collectionFormat,
      MethodMetadata methodMetadata,
      Target<?> feignTarget); @Deprecated  RequestTemplate(RequestTemplate toCopy); static RequestTemplate from(RequestTemplate requestTemplate); RequestTemplate resolve(Map<String, ?> variables); Request request(); @Deprecated RequestTemplate method(String method); RequestTemplate method(HttpMethod method); String method(); RequestTemplate decodeSlash(boolean decodeSlash); boolean decodeSlash(); RequestTemplate collectionFormat(CollectionFormat collectionFormat); @SuppressWarnings("unused") CollectionFormat collectionFormat(); @Deprecated RequestTemplate append(CharSequence value); @SuppressWarnings("unused") @Deprecated RequestTemplate insert(int pos, CharSequence value); RequestTemplate uri(String uri); RequestTemplate uri(String uri, boolean append); RequestTemplate target(String target); String url(); String path(); List<String> variables(); RequestTemplate query(String name, String... values); RequestTemplate query(String name, Iterable<String> values); RequestTemplate query(String name,
                               Iterable<String> values,
                               CollectionFormat collectionFormat); @SuppressWarnings("unused") RequestTemplate queries(Map<String, Collection<String>> queries); Map<String, Collection<String>> queries(); RequestTemplate header(String name, String... values); RequestTemplate header(String name, Iterable<String> values); RequestTemplate removeHeader(String name); RequestTemplate headers(Map<String, Collection<String>> headers); Map<String, Collection<String>> headers(); RequestTemplate body(byte[] data, Charset charset); RequestTemplate body(String bodyText); @Deprecated RequestTemplate body(Request.Body body); Charset requestCharset(); byte[] body(); @Deprecated Request.Body requestBody(); RequestTemplate bodyTemplate(String bodyTemplate); RequestTemplate bodyTemplate(String bodyTemplate, Charset charset); String bodyTemplate(); @Override String toString(); boolean hasRequestVariable(String variable); Collection<String> getRequestVariables(); @SuppressWarnings("unused") boolean resolved(); String queryLine(); @Experimental RequestTemplate methodMetadata(MethodMetadata methodMetadata); @Experimental RequestTemplate feignTarget(Target<?> feignTarget); @Experimental MethodMetadata methodMetadata(); @Experimental Target<?> feignTarget();  }