Interface EmailConfirmationManager
public interface EmailConfirmationManager
Confirmation manager for email attribute or identity
- Author:
- P. Piernik
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetConfirmationConfigurationForAttribute
(String attributeName) processConfirmation
(String tokenValue) Process confirmation based on token.void
Send confirmation request to the user with confirmation state.<T> void
sendVerification
(EntityParam entity, Attribute attribute) Sends confirmation messages for the values of an attribute which are verifiable, only for unconfirmed attributes ones.void
sendVerification
(EntityParam entity, Identity identity) see#sendVerificationNoTx(EntityParam, Identity)
, the only difference is that this method starts its own transactionvoid
sendVerificationNoTx
(EntityParam entity, Identity identity, boolean force) see#sendVerificationQuiet(EntityParam, Identity)
, the only difference is that this method throws exception.<T> void
sendVerificationQuietNoTx
(EntityParam entity, Attribute attribute, boolean force) Sends confirmation messages for the values of an attribute which are verifiable, only for unconfirmed attributes for which a confirmation was not yet sent.void
sendVerificationQuietNoTx
(EntityParam entity, Identity identity, boolean force) Sends confirmation messages for the identity if it requires so.void
sendVerificationsQuietNoTx
(EntityParam entity, Collection<? extends Attribute> attributes, boolean force) Sends confirmation messages for the values which requires so.
-
Field Details
-
CONFIRMATION_TOKEN_TYPE
- See Also:
-
-
Method Details
-
sendConfirmationRequest
Send confirmation request to the user with confirmation state. Confirmations configuration appropriate for the confirmation is used to establish message template id. The template is filled by manager with confirmation link and the whole message is sent via configured notification channel.- Parameters:
state
-- Throws:
EngineException
-
processConfirmation
Process confirmation based on token.- Parameters:
tokenValue
-- Returns:
- Confirmation status which contains user message key and args
- Throws:
EngineException
-
sendVerificationQuietNoTx
Sends confirmation messages for the values of an attribute which are verifiable, only for unconfirmed attributes for which a confirmation was not yet sent. In case of error only log entry is printed, no exception is thrown.WARNING: this method requires to set up existing transaction
- Parameters:
entity
-attribute
-force
- if true then request is sent even if one was already sent previously
-
sendVerification
Sends confirmation messages for the values of an attribute which are verifiable, only for unconfirmed attributes ones.- Parameters:
entity
-attribute
-- Throws:
EngineException
-
sendVerificationQuietNoTx
Sends confirmation messages for the identity if it requires so. Only for unconfirmed identities. In case of error only log entry is printed, no exception is thrown.WARNING: this method requires to set up existing transaction
- Parameters:
entity
-identity
-force
- if true then request is sent even if one was already sent previously
-
sendVerificationNoTx
void sendVerificationNoTx(EntityParam entity, Identity identity, boolean force) throws EngineException see#sendVerificationQuiet(EntityParam, Identity)
, the only difference is that this method throws exception.WARNING: this method requires to set up existing transaction
- Parameters:
entity
-identity
-force
- if true then request is sent even if one was already sent previously- Throws:
EngineException
-
sendVerification
see#sendVerificationNoTx(EntityParam, Identity)
, the only difference is that this method starts its own transaction- Parameters:
entity
-identity
-force
- if true then request is sent even if one was already sent previously- Throws:
EngineException
-
sendVerificationsQuietNoTx
void sendVerificationsQuietNoTx(EntityParam entity, Collection<? extends Attribute> attributes, boolean force) Sends confirmation messages for the values which requires so. Only for unconfirmed attributes.WARNING: this method requires to set up existing transaction
- Parameters:
entity
-attribute
-force
- if true then request is sent even if one was already sent previously
-
getConfirmationConfigurationForAttribute
Optional<EmailConfirmationConfiguration> getConfirmationConfigurationForAttribute(String attributeName) - Returns:
- attribute confirmation configuration
-