Class SotpFieldTemplate
java.lang.Object
org.bardframework.form.field.FieldTemplate<F>
org.bardframework.form.field.input.InputFieldTemplate<F,T>
org.bardframework.flow.form.field.input.FlowInputFieldTemplate<F,String>
org.bardframework.flow.form.field.input.otp.OtpFieldTemplate<OtpField,String>
org.bardframework.flow.form.field.input.otp.sms.SotpFieldTemplate
-
Field Summary
Fields inherited from class org.bardframework.flow.form.field.input.FlowInputFieldTemplate
actionProcessorsFields inherited from class org.bardframework.form.field.input.InputFieldTemplate
descriptionShowType, persistentValue, valueProviderFields inherited from class org.bardframework.form.field.FieldTemplate
defaultValues, fieldClazz, log, name, showExpression -
Constructor Summary
ConstructorsConstructorDescriptionSotpFieldTemplate(String name, OtpGenerator<String> otpGenerator, int maxTryToResolveCount, MessageSenderSms messageSender) -
Method Summary
Modifier and TypeMethodDescriptionprotected Stringprotected booleanvoidpreProcess(String flowToken, Map<String, String> flowData, Locale locale, jakarta.servlet.http.HttpServletResponse httpResponse) protected voidsend(String flowToken, Map<String, String> flowData, String otp, Locale locale, jakarta.servlet.http.HttpServletResponse httpResponse) Methods inherited from class org.bardframework.flow.form.field.input.otp.OtpFieldTemplate
fill, getCanEditIdentifier, getMaxSendCount, getMaxTryToResolveCount, getOtpGenerator, getResendIntervalSeconds, isValid, resend, sendInternal, setCanEditIdentifier, setMaxSendCount, setResendIntervalSeconds, toValueMethods inherited from class org.bardframework.flow.form.field.input.FlowInputFieldTemplate
getActionProcessors, setActionProcessorsMethods inherited from class org.bardframework.form.field.input.InputFieldTemplate
getDescriptionShowType, getValidationOrder, getValueProvider, isPersistentValue, setDescriptionShowType, setPersistentValue, setValueProvider, validate, validateMethods inherited from class org.bardframework.form.field.FieldTemplate
getDefaultValues, getEmptyField, getFieldClazz, getLog, getName, getShowExpression, mustShow, setDefaultValues, setShowExpression, toField
-
Constructor Details
-
SotpFieldTemplate
public SotpFieldTemplate(String name, OtpGenerator<String> otpGenerator, int maxTryToResolveCount, MessageSenderSms messageSender)
-
-
Method Details
-
send
protected void send(String flowToken, Map<String, String> flowData, String otp, Locale locale, jakarta.servlet.http.HttpServletResponse httpResponse) throws Exception- Specified by:
sendin classOtpFieldTemplate<OtpField,String> - Throws:
Exception
-
preProcess
public void preProcess(String flowToken, Map<String, String> flowData, Locale locale, jakarta.servlet.http.HttpServletResponse httpResponse) throws Exception- Overrides:
preProcessin classFlowInputFieldTemplate<OtpField,String> - Throws:
Exception
-
isValidOtp
protected boolean isValidOtp(String flowToken, String otp, Map<String, String> flowData) throws Exception- Specified by:
isValidOtpin classOtpFieldTemplate<OtpField,String> - Throws:
Exception
-
getResendAction
- Specified by:
getResendActionin classOtpFieldTemplate<OtpField,String>
-