Package org.eclipse.jetty.client
Class HttpAuthenticationStore
- java.lang.Object
-
- org.eclipse.jetty.client.HttpAuthenticationStore
-
- All Implemented Interfaces:
AuthenticationStore
public class HttpAuthenticationStore extends java.lang.Object implements AuthenticationStore
-
-
Constructor Summary
Constructors Constructor Description HttpAuthenticationStore()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addAuthentication(Authentication authentication)
void
addAuthenticationResult(Authentication.Result result)
void
clearAuthenticationResults()
Removes all authentication results storedvoid
clearAuthentications()
Removes allAuthentication
s storedAuthentication
findAuthentication(java.lang.String type, java.net.URI uri, java.lang.String realm)
Returns the authentication that matches the given type (for example, "Basic" or "Digest"), the given request URI and the given realm.Authentication.Result
findAuthenticationResult(java.net.URI uri)
Returns anAuthentication.Result
that matches the given URI, or null if noAuthentication.Result
s match the given URI.boolean
hasAuthenticationResults()
void
removeAuthentication(Authentication authentication)
void
removeAuthenticationResult(Authentication.Result result)
-
-
-
Method Detail
-
addAuthentication
public void addAuthentication(Authentication authentication)
- Specified by:
addAuthentication
in interfaceAuthenticationStore
- Parameters:
authentication
- theAuthentication
to add
-
removeAuthentication
public void removeAuthentication(Authentication authentication)
- Specified by:
removeAuthentication
in interfaceAuthenticationStore
- Parameters:
authentication
- theAuthentication
to remove
-
clearAuthentications
public void clearAuthentications()
Description copied from interface:AuthenticationStore
Removes allAuthentication
s stored- Specified by:
clearAuthentications
in interfaceAuthenticationStore
-
findAuthentication
public Authentication findAuthentication(java.lang.String type, java.net.URI uri, java.lang.String realm)
Description copied from interface:AuthenticationStore
Returns the authentication that matches the given type (for example, "Basic" or "Digest"), the given request URI and the given realm. If no such authentication can be found, returns null.- Specified by:
findAuthentication
in interfaceAuthenticationStore
- Parameters:
type
- theAuthentication
type such as "Basic" or "Digest"uri
- the request URIrealm
- the authentication realm- Returns:
- the authentication that matches the given parameters, or null
-
addAuthenticationResult
public void addAuthenticationResult(Authentication.Result result)
- Specified by:
addAuthenticationResult
in interfaceAuthenticationStore
- Parameters:
result
- theAuthentication.Result
to add
-
removeAuthenticationResult
public void removeAuthenticationResult(Authentication.Result result)
- Specified by:
removeAuthenticationResult
in interfaceAuthenticationStore
- Parameters:
result
- theAuthentication.Result
to remove
-
clearAuthenticationResults
public void clearAuthenticationResults()
Description copied from interface:AuthenticationStore
Removes all authentication results stored- Specified by:
clearAuthenticationResults
in interfaceAuthenticationStore
-
findAuthenticationResult
public Authentication.Result findAuthenticationResult(java.net.URI uri)
Description copied from interface:AuthenticationStore
Returns anAuthentication.Result
that matches the given URI, or null if noAuthentication.Result
s match the given URI.- Specified by:
findAuthenticationResult
in interfaceAuthenticationStore
- Parameters:
uri
- the request URI- Returns:
- the
Authentication.Result
that matches the given URI, or null
-
hasAuthenticationResults
public boolean hasAuthenticationResults()
- Specified by:
hasAuthenticationResults
in interfaceAuthenticationStore
- Returns:
- false if there are no stored authentication results, true if there may be some.
-
-