rlalfo / google-http-java-client

Automatically exported from code.google.com/p/google-http-java-client
0 stars 0 forks source link

UriTemplate does not work for query parameters. #268

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Version of google-http-java-client 1.19.0

Java environment java 7

    String url = UriTemplate.expand("http://localhost:9999/ldap/users{?anyName}", ImmutableMap.of("anyName", "john"), false);
    System.out.println("url = " + url);

returns:

http://localhost:9999/ldap/usersjohn

based on the RFC it should return:

http://localhost:9999/ldap/users?anyName=john

RFC example:

{?who}     ->        ?who=fred

Original issue reported on code.google.com by zolyfar...@yahoo.com on 25 Nov 2014 at 6:26