Class SuggestBoxWithEditorErrors
java.lang.Object
com.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.Widget
com.google.gwt.user.client.ui.Composite
com.google.gwt.user.client.ui.AbstractSuggestBoxNewEditor
de.knightsoftnet.mtwidgets.client.ui.widget.SuggestBoxNewEditor
de.knightsoftnet.mtwidgets.client.ui.widget.SuggestBoxWithEditorErrors
- All Implemented Interfaces:
com.google.gwt.event.dom.client.HasAllKeyHandlers,com.google.gwt.event.dom.client.HasBlurHandlers,com.google.gwt.event.dom.client.HasFocusHandlers,com.google.gwt.event.dom.client.HasKeyDownHandlers,com.google.gwt.event.dom.client.HasKeyPressHandlers,com.google.gwt.event.dom.client.HasKeyUpHandlers,com.google.gwt.event.logical.shared.HasAttachHandlers,com.google.gwt.event.logical.shared.HasSelectionHandlers<com.google.gwt.user.client.ui.SuggestOracle.Suggestion>,com.google.gwt.event.logical.shared.HasValueChangeHandlers<String>,com.google.gwt.event.shared.HasHandlers,com.google.gwt.user.client.EventListener,com.google.gwt.user.client.TakesValue<String>,com.google.gwt.user.client.ui.Focusable,com.google.gwt.user.client.ui.HasAnimation,com.google.gwt.user.client.ui.HasEnabled,com.google.gwt.user.client.ui.HasText,com.google.gwt.user.client.ui.HasValue<String>,com.google.gwt.user.client.ui.HasVisibility,com.google.gwt.user.client.ui.IsRenderable,com.google.gwt.user.client.ui.IsWidget,HasAutocomplete,HasAutofocus,HasPlaceholder,HasRequired,HasValidationMessageElement<String,,org.gwtproject.editor.client.LeafValueEditor<String>> HasValidity,org.gwtproject.editor.client.Editor<String>,org.gwtproject.editor.client.HasEditorErrors<String>,org.gwtproject.editor.client.IsEditor<org.gwtproject.editor.client.LeafValueEditor<String>>,org.gwtproject.editor.client.TakesValue<String>
- Direct Known Subclasses:
AbstractFormatingSuggestBox,BicSuggestBox
public class SuggestBoxWithEditorErrors
extends SuggestBoxNewEditor
implements com.google.gwt.event.dom.client.HasFocusHandlers, com.google.gwt.event.dom.client.HasBlurHandlers, HasValidationMessageElement<String,org.gwtproject.editor.client.LeafValueEditor<String>>, HasRequired, HasValidity, HasAutofocus, HasPlaceholder, HasAutocomplete
Text input box with suggestions and editor error handling.
-
Nested Class Summary
Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.AbstractSuggestBoxNewEditor
AbstractSuggestBoxNewEditor.DefaultSuggestionDisplay, AbstractSuggestBoxNewEditor.SuggestionCallback, AbstractSuggestBoxNewEditor.SuggestionDisplayNested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.UIObject.DebugIdImpl, com.google.gwt.user.client.ui.UIObject.DebugIdImplEnabledNested classes/interfaces inherited from interface org.gwtproject.editor.client.Editor
org.gwtproject.editor.client.Editor.Ignore, org.gwtproject.editor.client.Editor.Path -
Field Summary
Fields inherited from class com.google.gwt.user.client.ui.AbstractSuggestBoxNewEditor
callback, currentText, display, limit, oracle, selectsFirstItem, STYLENAME_DEFAULTFields inherited from class com.google.gwt.user.client.ui.UIObject
DEBUG_ID_PREFIX -
Constructor Summary
ConstructorsConstructorDescriptionConstructor forSuggestBox.SuggestBoxWithEditorErrors(com.google.gwt.user.client.ui.SuggestOracle oracle) Constructor forSuggestBox.SuggestBoxWithEditorErrors(com.google.gwt.user.client.ui.SuggestOracle oracle, ValueBoxBaseWithEditorErrors<String> box) Constructor forSuggestBox.SuggestBoxWithEditorErrors(com.google.gwt.user.client.ui.SuggestOracle oracle, ValueBoxBaseWithEditorErrors<String> box, AbstractSuggestBoxNewEditor.SuggestionDisplay suggestDisplay) Constructor forSuggestBox. -
Method Summary
Modifier and TypeMethodDescriptioncom.google.gwt.event.shared.HandlerRegistrationaddBlurHandler(com.google.gwt.event.dom.client.BlurHandler handler) com.google.gwt.event.shared.HandlerRegistrationaddFocusHandler(com.google.gwt.event.dom.client.FocusHandler handler) booleanReturns false if the element is a candidate for constraint validation, and it does not satisfy its constraints.get autocomplete attribute value.get place holder text.A localized message that describes the validation constraints that the control does not satisfy (if any).com.google.gwt.user.client.ui.HTMLPanelget validation message element.elemental2.dom.ValidityStateThe validity states that this element is in.booleanget autofocus value.booleanReflects therequiredHTML attribute, indicating that the user must fill in a value before submitting a form.voidsetAutocomplete(String arg) set autocomplete attribute value.voidsetAutofocus(boolean arg) set autofocus value.voidsetCustomValidity(String message) set custom validity value.voidsetPlaceholder(String placeholder) set place holder text.voidsetRequired(boolean arg) Reflects therequiredHTML attribute, indicating that the user must fill in a value before submitting a form.voidsetValidationMessageElement(com.google.gwt.user.client.ui.HTMLPanel element) set validation message element.Methods inherited from class de.knightsoftnet.mtwidgets.client.ui.widget.SuggestBoxNewEditor
addEventsToTextBox, asEditor, getBoxAsFoucsWidget, getTabIndex, getText, getValue, getValueBox, isEnabled, setAccessKey, setEnabled, setFocus, setTabIndex, setText, setValue, setValue, wrapMethods inherited from class com.google.gwt.user.client.ui.AbstractSuggestBoxNewEditor
addEventsToTextBox, addKeyDownHandler, addKeyPressHandler, addKeyUpHandler, addSelectionHandler, addValueChangeHandler, getLimit, getSuggestionDisplay, getSuggestOracle, hideSuggestionList, isAnimationEnabled, isAutoSelectEnabled, isSuggestionListShowing, onEnsureDebugId, refreshSuggestionList, setAnimationEnabled, setAutoSelectEnabled, setLimit, setOracle, setPopupStyleName, showSuggestionListMethods inherited from class com.google.gwt.user.client.ui.Composite
claimElement, getWidget, initializeClaimedElement, initWidget, isAttached, onAttach, onBrowserEvent, onDetach, render, render, resolvePotentialElement, setWidgetMethods inherited from class com.google.gwt.user.client.ui.Widget
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getHandlerCount, getLayoutData, getParent, isOrWasAttached, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents, unsinkEventsMethods inherited from class com.google.gwt.user.client.ui.UIObject
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, removeStyleDependentName, removeStyleName, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.gwt.event.shared.HasHandlers
fireEventMethods inherited from interface de.knightsoftnet.mtwidgets.client.ui.widget.features.HasValidationMessageElement
editorErrorMatches, setTitle, showErrors, showErrorsMethods inherited from interface org.gwtproject.editor.client.IsEditor
asEditor
-
Constructor Details
-
SuggestBoxWithEditorErrors
public SuggestBoxWithEditorErrors()Constructor forSuggestBox. Creates aMultiWordSuggestOracleandTextBoxto use with thisSuggestBox. -
SuggestBoxWithEditorErrors
public SuggestBoxWithEditorErrors(com.google.gwt.user.client.ui.SuggestOracle oracle) - Parameters:
oracle- the oracle for thisSuggestBox
-
SuggestBoxWithEditorErrors
public SuggestBoxWithEditorErrors(com.google.gwt.user.client.ui.SuggestOracle oracle, ValueBoxBaseWithEditorErrors<String> box) Constructor forSuggestBox. The text box will be removed from it's current location and wrapped by theSuggestBox.- Parameters:
oracle- supplies suggestions based upon the current contents of the text widgetbox- the text widget
-
SuggestBoxWithEditorErrors
public SuggestBoxWithEditorErrors(com.google.gwt.user.client.ui.SuggestOracle oracle, ValueBoxBaseWithEditorErrors<String> box, AbstractSuggestBoxNewEditor.SuggestionDisplay suggestDisplay) Constructor forSuggestBox. The text box will be removed from it's current location and wrapped by theSuggestBox.- Parameters:
oracle- supplies suggestions based upon the current contents of the text widgetbox- the text widgetsuggestDisplay- the class used to display suggestions
-
-
Method Details
-
addBlurHandler
public com.google.gwt.event.shared.HandlerRegistration addBlurHandler(com.google.gwt.event.dom.client.BlurHandler handler) - Specified by:
addBlurHandlerin interfacecom.google.gwt.event.dom.client.HasBlurHandlers
-
addFocusHandler
public com.google.gwt.event.shared.HandlerRegistration addFocusHandler(com.google.gwt.event.dom.client.FocusHandler handler) - Specified by:
addFocusHandlerin interfacecom.google.gwt.event.dom.client.HasFocusHandlers
-
getValidationMessage
Description copied from interface:HasValidityA localized message that describes the validation constraints that the control does not satisfy (if any). This is the empty string if the control is not a candidate for constraint validation (willValidate is false), or it satisfies its constraints.- Specified by:
getValidationMessagein interfaceHasValidity- Returns:
- localized validation message
-
getValidity
public elemental2.dom.ValidityState getValidity()Description copied from interface:HasValidityThe validity states that this element is in.- Specified by:
getValidityin interfaceHasValidity- Returns:
- ValidityState
-
checkValidity
public boolean checkValidity()Description copied from interface:HasValidityReturns false if the element is a candidate for constraint validation, and it does not satisfy its constraints. In this case, it also fires aninvalidevent at the element. It returns true if the element is not a candidate for constraint validation, or if it satisfies its constraints.- Specified by:
checkValidityin interfaceHasValidity- Returns:
- true if input is valid
-
isRequired
public boolean isRequired()Description copied from interface:HasRequiredReflects therequiredHTML attribute, indicating that the user must fill in a value before submitting a form.- Specified by:
isRequiredin interfaceHasRequired- Returns:
- required true/false
-
setRequired
public void setRequired(boolean arg) Description copied from interface:HasRequiredReflects therequiredHTML attribute, indicating that the user must fill in a value before submitting a form.- Specified by:
setRequiredin interfaceHasRequired- Parameters:
arg- required true/false
-
isAutofocus
public boolean isAutofocus()Description copied from interface:HasAutofocusget autofocus value.- Specified by:
isAutofocusin interfaceHasAutofocus- Returns:
- true if input field has autofocus
-
setAutofocus
public void setAutofocus(boolean arg) Description copied from interface:HasAutofocusset autofocus value.- Specified by:
setAutofocusin interfaceHasAutofocus- Parameters:
arg- true if input field has autofocus
-
setValidationMessageElement
public void setValidationMessageElement(com.google.gwt.user.client.ui.HTMLPanel element) Description copied from interface:HasValidationMessageElementset validation message element.- Specified by:
setValidationMessageElementin interfaceHasValidationMessageElement<String,org.gwtproject.editor.client.LeafValueEditor<String>> - Parameters:
element- element to set
-
getValidationMessageElement
public com.google.gwt.user.client.ui.HTMLPanel getValidationMessageElement()Description copied from interface:HasValidationMessageElementget validation message element.- Specified by:
getValidationMessageElementin interfaceHasValidationMessageElement<String,org.gwtproject.editor.client.LeafValueEditor<String>> - Returns:
- element or null if non is set
-
getPlaceholder
Description copied from interface:HasPlaceholderget place holder text.- Specified by:
getPlaceholderin interfaceHasPlaceholder- Returns:
- place holder text displayed when value is empty
-
setPlaceholder
Description copied from interface:HasPlaceholderset place holder text.- Specified by:
setPlaceholderin interfaceHasPlaceholder- Parameters:
placeholder- place holder text displayed when value is empty
-
getAutocomplete
Description copied from interface:HasAutocompleteget autocomplete attribute value.- Specified by:
getAutocompletein interfaceHasAutocomplete- Returns:
- input field autocomplete attribute value
-
setAutocomplete
Description copied from interface:HasAutocompleteset autocomplete attribute value.- Specified by:
setAutocompletein interfaceHasAutocomplete- Parameters:
arg- input field autocomplete attribute value to set
-
setCustomValidity
Description copied from interface:HasValidationMessageElementset custom validity value.- Specified by:
setCustomValidityin interfaceHasValidationMessageElement<String,org.gwtproject.editor.client.LeafValueEditor<String>> - Parameters:
message- message to show
-