A
- the type of Authenticator
that accepts this credentialpublic abstract class Credential<A extends Authenticator> extends Object
Modifier | Constructor and Description |
---|---|
protected |
Credential(Class<A> authenticatorType) |
Modifier and Type | Method and Description |
---|---|
abstract void |
authenticate(A authenticator)
Authenticates the connection managed by the given
Authenticator
using this credential. |
Class<A> |
getAuthenticatorType()
Returns the type of
Authenticator accepted by this credential. |
public final Class<A> getAuthenticatorType()
Authenticator
accepted by this credential.public abstract void authenticate(A authenticator) throws IOException
Authenticator
using this credential.
This method participates in the visitor pattern with methods defined by
Authenticator
implementations.
authenticator
- the Authenticator
for the connectionAuthenticationException
- if authentication failsIOException
- if an I/O error occurs while authenticating the
connection