Class OtpCompleteEvent
java.lang.Object
java.util.EventObject
com.vaadin.flow.component.ComponentEvent<OtpField>
com.flowingcode.vaadin.addons.otpfield.OtpCompleteEvent
- All Implemented Interfaces:
Serializable
Fired when the code entered in an
OtpField is complete, that is, when its length reaches
OtpField.getLength().
The event is fired regardless of the ValueChangeMode of the
field, and it is fired again whenever the user edits a complete code into a different one: by
replacing a character of it, by pasting another code over it, or by making it incomplete and
completing it once more. Every event therefore carries a code that has not been reported before
it, which is what an application verifying the code needs. It is not fired for a programmatic
OtpField.setValue(String).
- Since:
- 1.0.0
- Author:
- Flowing Code
- See Also:
-
Field Summary
Fields inherited from class java.util.EventObject
source -
Constructor Summary
ConstructorsConstructorDescriptionOtpCompleteEvent(OtpField source, boolean fromClient, String value) Creates a new complete event. -
Method Summary
Methods inherited from class com.vaadin.flow.component.ComponentEvent
getSource, getUI, isFromClient, unregisterListenerMethods inherited from class java.util.EventObject
toString
-
Constructor Details
-
OtpCompleteEvent
public OtpCompleteEvent(OtpField source, boolean fromClient, @EventData("event.detail.value") String value) Creates a new complete event.- Parameters:
source- the field that fired the eventfromClient-trueif the event originated from the client sidevalue- the complete code
-