Class AbstractCredentialRetrieval<T extends CredentialExchange>
- java.lang.Object
-
- pl.edu.icm.unity.engine.api.authn.AbstractCredentialRetrieval<T>
-
- All Implemented Interfaces:
CredentialRetrieval
,BindingAuthn
,StringConfigurable
public abstract class AbstractCredentialRetrieval<T extends CredentialExchange> extends java.lang.Object implements CredentialRetrieval
Common code for allCredentialRetrieval
implementations. Stores the exchange implementation and instance name. Useful for all implementations supporting a single type of credential exchange (what is by far the common case).- Author:
- K. Benedyczak
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.String
bindingName
protected T
credentialExchange
-
Constructor Summary
Constructors Constructor Description AbstractCredentialRetrieval(java.lang.String bindingName)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
destroy()
Called when endpoint using this implementation is destroyed.java.lang.String
getAuthenticatorId()
java.lang.String
getBindingName()
void
setCredentialExchange(CredentialExchange e, java.lang.String id)
Sets initial state, given by the framework (the retrieval's own, implementation specific configuration is set via#setSerializedConfiguration(com.fasterxml.jackson.databind.node.ObjectNode)
): the credential verificator and the configured id.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface pl.edu.icm.unity.engine.api.authn.CredentialRetrieval
requiresRedirect
-
Methods inherited from interface pl.edu.icm.unity.engine.api.utils.StringConfigurable
getSerializedConfiguration, setSerializedConfiguration
-
-
-
-
Field Detail
-
credentialExchange
protected T extends CredentialExchange credentialExchange
-
bindingName
protected final java.lang.String bindingName
-
-
Method Detail
-
getBindingName
public java.lang.String getBindingName()
- Specified by:
getBindingName
in interfaceBindingAuthn
- Specified by:
getBindingName
in interfaceCredentialRetrieval
- Returns:
- implementation id
-
setCredentialExchange
public void setCredentialExchange(CredentialExchange e, java.lang.String id)
Description copied from interface:CredentialRetrieval
Sets initial state, given by the framework (the retrieval's own, implementation specific configuration is set via#setSerializedConfiguration(com.fasterxml.jackson.databind.node.ObjectNode)
): the credential verificator and the configured id.- Specified by:
setCredentialExchange
in interfaceCredentialRetrieval
-
getAuthenticatorId
public java.lang.String getAuthenticatorId()
- Specified by:
getAuthenticatorId
in interfaceBindingAuthn
- Returns:
- name of the configured authenticator instance.
-
destroy
public void destroy()
Description copied from interface:BindingAuthn
Called when endpoint using this implementation is destroyed.- Specified by:
destroy
in interfaceBindingAuthn
-
-