Interface AuthCache
- All Known Implementing Classes:
BasicAuthCache
public interface AuthCache
This interface represents an cache of
AuthScheme state information
that can be re-used for preemptive authentication by subsequent requests.- Since:
- 4.1
-
Method Summary
Modifier and TypeMethodDescriptionvoidclear()get(org.apache.hc.core5.http.HttpHost host) Returns the authentication state with the given authentication scope from the cache if available.default AuthSchemeReturns the authentication state with the given authentication scope from the cache if available.default voidput(org.apache.hc.core5.http.HttpHost host, String pathPrefix, AuthScheme authScheme) Stores the authentication state with the given authentication scope in the cache.voidput(org.apache.hc.core5.http.HttpHost host, AuthScheme authScheme) Stores the authentication state with the given authentication scope in the cache.voidremove(org.apache.hc.core5.http.HttpHost host) Removes the authentication state with the given authentication scope from the cache if found.default voidRemoves the authentication state with the given authentication scope from the cache if found.
-
Method Details
-
put
Stores the authentication state with the given authentication scope in the cache.- Parameters:
host- the authentication authority.authScheme- the cacheable authentication state.
-
get
Returns the authentication state with the given authentication scope from the cache if available.- Parameters:
host- the authentication authority.- Returns:
- the authentication state ir
nullif not available in the cache.
-
remove
void remove(org.apache.hc.core5.http.HttpHost host) Removes the authentication state with the given authentication scope from the cache if found.- Parameters:
host- the authentication authority.
-
clear
void clear() -
put
Stores the authentication state with the given authentication scope in the cache.- Parameters:
host- the authentication authority.pathPrefix- the path prefix (the path component up to the last segment separator). Can benull.authScheme- the cacheable authentication state.- Since:
- 5.2
-
get
Returns the authentication state with the given authentication scope from the cache if available.- Parameters:
host- the authentication authority.pathPrefix- the path prefix (the path component up to the last segment separator). Can benull.- Returns:
- the authentication state ir
nullif not available in the cache. - Since:
- 5.2
-
remove
Removes the authentication state with the given authentication scope from the cache if found.- Parameters:
host- the authentication authority.pathPrefix- the path prefix (the path component up to the last segment separator). Can benull.- Since:
- 5.2
-