1
0
mirror of https://github.com/square/okhttp.git synced 2026-01-18 20:40:58 +03:00

Drop getHeaders() which is redundant with headers().

This commit is contained in:
Jesse Wilson
2014-05-21 00:35:51 -04:00
parent 3d0d59c2b7
commit 9e233ca544
3 changed files with 3 additions and 6 deletions

View File

@@ -90,10 +90,6 @@ public final class Request {
return new Builder(this);
}
public Headers getHeaders() {
return headers;
}
/**
* Returns the cache control directives for this response. This is never null,
* even if this response contains no {@code Cache-Control} header.

View File

@@ -60,7 +60,8 @@ public final class Route {
* Returns the {@link Proxy} of this route.
*
* <strong>Warning:</strong> This may disagree with {@link Address#getProxy}
* is null. When the address's proxy is null, the proxy selector will be used.
* when it is null. When the address's proxy is null, the proxy selector is
* used.
*/
public Proxy getProxy() {
return proxy;

View File

@@ -94,7 +94,7 @@ public final class HttpTransport implements Transport {
String requestLine = RequestLine.get(request,
httpEngine.getConnection().getRoute().getProxy().type(),
httpEngine.getConnection().getProtocol());
httpConnection.writeRequest(request.getHeaders(), requestLine);
httpConnection.writeRequest(request.headers(), requestLine);
}
@Override public Response.Builder readResponseHeaders() throws IOException {