mirror of
https://github.com/square/okhttp.git
synced 2026-01-15 20:56:41 +03:00
Nullable route annotation (#4257)
* Nullable route annotation * Fix comment to mention intranet example
This commit is contained in:
committed by
Jesse Wilson
parent
1df923143f
commit
7bdedbe624
@@ -70,6 +70,13 @@ public interface Authenticator {
|
||||
/**
|
||||
* Returns a request that includes a credential to satisfy an authentication challenge in {@code
|
||||
* response}. Returns null if the challenge cannot be satisfied.
|
||||
*
|
||||
* The route is best effort, it currently may not always be provided even when logically
|
||||
* available. It may also not be provided when an Authenticator is re-used manually in
|
||||
* an application interceptor, e.g. implementing client specific retries.
|
||||
*
|
||||
* @param route The route for evaluating how to respond to a challenge e.g. via intranet.
|
||||
* @param response The response containing the auth challenges to respond to.
|
||||
*/
|
||||
@Nullable Request authenticate(Route route, Response response) throws IOException;
|
||||
@Nullable Request authenticate(@Nullable Route route, Response response) throws IOException;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user