I want to know from which server a response comes.
With a HttpMethod I'm readig the HttpStatus, the Method-Name and other stuff. But how do I get to know the Response-Server?
Thanks for any help.
Edit:
boolean checkR(HttpMethod method){
if (method.getStatusCode() == HttpStatus.SC_OK) {
return true;
} else {
System.out.println("HTTP response was " + method.getStatusLine().toString());
return false;
}
}
I would like to return something like this: "HTTP response was " + method.getStatusLine().toString()) + "from Server " + ??? Server-name ??
;