HttpRequest extends CertainlyCloneable<HttpRequest> { @Override public String toString() { return toString(false); } HttpRequest(); String getScheme(); String getHost(); int getPort(); String getPath(); List<KeyValuePair> getUrlOptions(); String getOption(String key, String defaultValue); List<KeyValuePair> getHeaders(); String getHeader(String key, String defaultValue); long getTimeoutMillis(); Object getPostContent(); HttpOp getHttpOperation(); HttpRequest setScheme(String scheme); HttpRequest setHost(String hostname); HttpRequest setPort(int port); HttpRequest setPath(String path); HttpRequest addUrlOption(String key, String value); HttpRequest setUrlOptions(List<KeyValuePair> options); HttpRequest addHttpHeader(String key, String value); HttpRequest setTimeout(long timeoutMillis); HttpRequest setPostContent(Object content); HttpRequest setHttpOperation(HttpOp op); HttpRequest merge(HttpRequest r); @Override HttpRequest clone(); @Override String toString(); String toString(boolean verbose); void verifyComplete(); boolean equals(Object o);  }
@Test public void testToString() { assertEquals("GET? http: new HttpRequest() .setScheme("http") .setHost("localhost") .setPort(8080) .toString(true)); assertEquals("POST http: new HttpRequest() .setScheme("http") .setHttpOperation(HttpRequest.HttpOp.POST) .setHost("localhost") .toString(true)); assertEquals("GET http: new HttpRequest() .setScheme("http") .setHttpOperation(HttpRequest.HttpOp.GET) .addUrlOption("foo", "bar") .setHost("localhost") .toString(true)); }