*/
class URIBuilder {
public URI getURI(String scheme, String host, int port, String path,
String queryString, HttpMethodParams params) throws URIException {
HttpHost httphost = new HttpHost(host, port);
StringBuffer buffer = new StringBuffer();
if (httphost != null) {
buffer.append(httphost.getProtocol().getScheme());
buffer.append("://");
buffer.append(httphost.getHostName());
int p = httphost.getPort();
if (p != -1 && p != httphost.getProtocol().getDefaultPort()) {
buffer.append(":");
buffer.append(p);
}
}
buffer.append(path);