Skip to content

Commit

Permalink
Go with more specific return type for fluent/covariant return values
Browse files Browse the repository at this point in the history
  • Loading branch information
jheintz committed Jul 15, 2014
1 parent ebec49c commit c9999fb
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/main/java/com/gistlabs/mechanize/impl/MechanizeAgent.java
Expand Up @@ -118,13 +118,13 @@ public void process(final HttpResponse response, final HttpContext context)
});
}

public Mechanize prefixFilter(final MechanizeChainFilter filter) {
public MechanizeAgent prefixFilter(final MechanizeChainFilter filter) {
this.requestChain.prefix(filter);
return this;
}


public Mechanize addFilter(final MechanizeChainFilter filter) {
public MechanizeAgent addFilter(final MechanizeChainFilter filter) {
this.requestChain.add(filter);
return this;
}
Expand All @@ -142,7 +142,7 @@ public static AbstractHttpClient buildDefaultHttpClient() {
* @param userAgent The value to set User-Agent HTTP parameter to for requests
* @return
*/
public Mechanize setUserAgent(final String userAgent) {
public MechanizeAgent setUserAgent(final String userAgent) {
HttpProtocolParams.setUserAgent(this.client.getParams(), userAgent);
return this;
}
Expand Down

0 comments on commit c9999fb

Please sign in to comment.