1private Uri buildURI(String url, Map<String, String> params) {
2
3 // build url with parameters.
4 Uri.Builder builder = Uri.parse(url).buildUpon();
5 for (Map.Entry<String, String> entry : params.entrySet()) {
6 builder.appendQueryParameter(entry.getKey(), entry.getValue());
7 }
8
9 return builder.build();
10}
11