Package com.storedobject.vaadin
Class InformationMessage
java.lang.Object
com.storedobject.vaadin.View
com.storedobject.vaadin.AbstractDataForm<Object>
com.storedobject.vaadin.DataForm
com.storedobject.vaadin.ActionForm
com.storedobject.vaadin.InformationMessage
- All Implemented Interfaces:
ClickHandler,ExecutableView,HasContainer,ValueChangeHandler,com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.ClickEvent<? extends com.vaadin.flow.component.Component>>,com.vaadin.flow.component.HasValue.ValueChangeListener,Serializable,Runnable,EventListener
An information message to be shown to the user. Some action can be specified when the "Ok" button is pressed.
- Author:
- Syam
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class com.storedobject.vaadin.AbstractDataForm
AbstractDataForm.FieldErrorNested classes/interfaces inherited from interface com.storedobject.vaadin.ClickHandler
ClickHandler.ModifiedClickEvent<C extends com.vaadin.flow.component.Component> -
Field Summary
Fields inherited from class com.storedobject.vaadin.DataForm
buttonPanel, cancel, okFields inherited from class com.storedobject.vaadin.AbstractDataForm
form -
Constructor Summary
ConstructorsConstructorDescriptionInformationMessage(com.vaadin.flow.component.Component message, Runnable action) Constructor.InformationMessage(com.vaadin.flow.component.Component message, Runnable action, String labelOk) Constructor.InformationMessage(String message) Constructor without any action (can be set later).InformationMessage(String caption, com.vaadin.flow.component.Component message, Runnable action) Constructor.InformationMessage(String caption, com.vaadin.flow.component.Component message, Runnable action, String labelOk) Constructor.InformationMessage(String message, Runnable action) Constructor.InformationMessage(String message, Runnable action, String labelOk) Constructor.InformationMessage(String caption, String message, Runnable action) Constructor.InformationMessage(String caption, String message, Runnable action, String labelOk) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionprotected voidBuild the buttons.static voidExecute an action after showing a informational message to the user.static voidExecute an action after showing a informational message to the user.protected StringGet the default caption.protected StringGet the default "Yes" label.voidSet the confirm action.voidsetCancelAction(Runnable actionNo) Set the cancel action.voidsetConfirmAction(Runnable action) Set the confirm action.Methods inherited from class com.storedobject.vaadin.ActionForm
buildFields, cancel, createFieldContainer, execute, getCancelAction, getConfirmAction, getDefaultNoLabel, process, setPreconfirmMethods inherited from class com.storedobject.vaadin.DataForm
clicked, getMaximumContentHeight, getMaximumContentWidth, getMinimumContentHeight, getMinimumContentWidth, initUI, setButtonsAtTop, setCloseable, setWindowMode, sizeSet, skipFirstFocus, validateDataMethods inherited from class com.storedobject.vaadin.AbstractDataForm
add, addConstructedListener, addField, addField, addIncludeFieldChecker, addValidator, addValidator, attachField, clean, clearAlerts, clearError, clearErrors, clearFields, commit, connect, connect, connect, createButtonLayout, createField, createField, createLayout, detachField, fieldAttached, fieldDetached, fireFormConstructed, formConstructed, getColumns, getColumnSpan, getContainer, getContent, getData, getErrorDisplay, getField, getFieldLabel, getFieldLabel, getFieldName, getFieldNames, getForm, getLabel, isFieldEditable, isFieldEditable, isFieldVisible, isFieldVisible, isReadOnly, load, markError, newLine, remove, removeAll, removeField, removeField, removeField, setColumns, setColumnSpan, setErrorDisplay, setFieldContainerProvider, setFieldCustomizer, setFieldEditable, setFieldEditable, setFieldHidden, setFieldHidden, setFieldLabel, setFieldLabel, setFieldReadOnly, setFieldReadOnly, setFieldReadOnly, setFieldReadOnly, setFieldVisible, setFieldVisible, setFieldVisible, setFieldVisible, setIncludeFieldChecker, setReadOnly, setRequired, setRequired, setRequired, setRequired, setRequired, setRequired, setRequired, setRequired, setRequired, streamFieldNamesCreated, streamFieldsCreatedMethods inherited from class com.storedobject.vaadin.View
abort, aborted, addClosedListener, addOpenedListener, close, createCloseableView, createWindow, decorateComponent, execute, execute, executing, focus, focus, focusAny, getApplication, getCaption, getComponent, getCreatedBy, getEmbeddedView, getMenuItem, getMenuItem, getView, invoke, isFullScreen, isScrollable, isWindowMode, select, setCaption, setComponent, setCreatedBy, setDefaultPadding, setEmbeddedView, setFirstFocus, setFullScreen, setScrollableMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.storedobject.vaadin.ClickHandler
clicked, doubleClicked, onComponentEvent, rightClickedMethods inherited from interface com.storedobject.vaadin.ExecutableView
createMenuItem, error, getMenuIconName, getView, isCloseable, isHomeView, log, log, message, returnedFrom, run, setClickable, speak, trackValueChange, tray, valueChanged, warningMethods inherited from interface com.storedobject.vaadin.ValueChangeHandler
valueChanged
-
Constructor Details
-
InformationMessage
Constructor without any action (can be set later).- Parameters:
message- Message to be shown
-
InformationMessage
-
InformationMessage
Constructor.- Parameters:
message- Message to be shownaction- Action when "Ok" button is pressed
-
InformationMessage
-
InformationMessage
-
InformationMessage
-
InformationMessage
-
InformationMessage
-
InformationMessage
-
-
Method Details
-
buildButtons
protected void buildButtons()Description copied from class:DataFormBuild the buttons. Button "Ok" and "Cancel" are already created. This method add those to theDataForm.buttonPanel. You can add additional custom buttons and components to theDataForm.buttonPanel.- Overrides:
buildButtonsin classDataForm
-
getDefaultCaption
Description copied from class:ActionFormGet the default caption.- Overrides:
getDefaultCaptionin classActionForm- Returns:
- The default caption.
-
getDefaultYesLabel
Description copied from class:ActionFormGet the default "Yes" label.- Overrides:
getDefaultYesLabelin classActionForm- Returns:
- The default label for the "Yes" button.
-
setConfirmAction
Description copied from class:ActionFormSet the confirm action.- Overrides:
setConfirmActionin classActionForm- Parameters:
action- Action from "Yes" button is pressed
-
setAction
Set the confirm action.- Parameters:
action- Action from "Ok" button is pressed
-
setCancelAction
Description copied from class:ActionFormSet the cancel action.- Overrides:
setCancelActionin classActionForm- Parameters:
actionNo- Action from "No" button is pressed
-
execute
-
execute
Execute an action after showing a informational message to the user.- Parameters:
message- Message to be shownaction- Action to be executed
-