Class AuthenticationParameters
java.lang.Object
jakarta.security.enterprise.authentication.mechanism.http.AuthenticationParameters
public class AuthenticationParameters
extends java.lang.Object
Parameters that are provided along with an authentication request.
-
Constructor Summary
Constructors Constructor Description AuthenticationParameters()
-
Method Summary
Modifier and Type Method Description AuthenticationParameters
credential(Credential credential)
Sets the credential to be used by the authentication mechanism responding to the authenticate call in which these AuthenticationParameters are passed.Credential
getCredential()
The credential set as parameter in this instance.boolean
isNewAuthentication()
Whether a new authentication dialog is required.boolean
isRememberMe()
Whether "remember me" should be used.AuthenticationParameters
newAuthentication(boolean newAuthentication)
Signal to the authentication mechanism responding to the authenticate call in which these AuthenticationParameters are passed, that an explicit new authentication dialog is required, as opposed to continuing a potentially existing one.AuthenticationParameters
rememberMe(boolean rememberMe)
Signals that for this call to the authentication mechanism "remember me" should be applied, IFF the "remember me" feature is configured for the authentication mechanism responding to the authenticate call.void
setCredential(Credential credential)
Sets the credential as parameter in this instance.void
setNewAuthentication(boolean newAuthentication)
Sets whether a new authentication dialog is required.void
setRememberMe(boolean rememberMe)
Sets whether "remember me" should be used.static AuthenticationParameters
withParams()
Creates a new instance of AuthenticationParameters, useful for a fluent/builder style creation of parameters.
-
Constructor Details
-
AuthenticationParameters
public AuthenticationParameters()
-
-
Method Details
-
withParams
Creates a new instance of AuthenticationParameters, useful for a fluent/builder style creation of parameters.- Returns:
- a new AuthenticationParameters instance.
-
credential
Sets the credential to be used by the authentication mechanism responding to the authenticate call in which these AuthenticationParameters are passed.- Parameters:
credential
- the credential to be used by the authentication mechanism- Returns:
- the instance of AuthenticationParameters on which this call was made, useful for a fluent/builder style creation of parameters.
-
newAuthentication
Signal to the authentication mechanism responding to the authenticate call in which these AuthenticationParameters are passed, that an explicit new authentication dialog is required, as opposed to continuing a potentially existing one.- Parameters:
newAuthentication
- whether a new authentication dialog is required to be started.- Returns:
- the instance of AuthenticationParameters on which this call was made, useful for a fluent/builder style creation of parameters.
-
rememberMe
Signals that for this call to the authentication mechanism "remember me" should be applied, IFF the "remember me" feature is configured for the authentication mechanism responding to the authenticate call.If "remember me" is not configured, this parameter is silently ignored.
- Parameters:
rememberMe
- iftrue
the "remember me" feature will be used if authentication succeeds and if so configured.- Returns:
- the instance of AuthenticationParameters on which this call was made, useful for a fluent/builder style creation of parameters.
- See Also:
RememberMe
,RememberMeIdentityStore
-
getCredential
The credential set as parameter in this instance.- Returns:
- the credential set as parameter in this instance
- See Also:
credential(Credential)
-
setCredential
Sets the credential as parameter in this instance.- Parameters:
credential
- the credential to be set as parameter in this instance.- See Also:
credential(Credential)
-
isNewAuthentication
public boolean isNewAuthentication()Whether a new authentication dialog is required.- Returns:
- whether a new authentication dialog is required.
- See Also:
newAuthentication(boolean)
-
setNewAuthentication
public void setNewAuthentication(boolean newAuthentication)Sets whether a new authentication dialog is required.- Parameters:
newAuthentication
- whether a new authentication dialog is required- See Also:
newAuthentication(boolean)
-
isRememberMe
public boolean isRememberMe()Whether "remember me" should be used.- Returns:
- whether "remember me" should be used.
- See Also:
rememberMe(boolean)
-
setRememberMe
public void setRememberMe(boolean rememberMe)Sets whether "remember me" should be used.- Parameters:
rememberMe
- whether "remember me" should be used.- See Also:
rememberMe(boolean)
-