public class Checkbox extends NodeBase implements INativeChangeListener, IControl<Boolean>, IHasModifiedIndication
| Constructor and Description |
|---|
Checkbox() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
acceptRequestParameter(String[] values) |
String |
getDisabledBecause() |
IValueChanged<?> |
getOnValueChanged()
Deprecated.
|
Boolean |
getValue()
Returns the current value of this input component.
|
Boolean |
getValueSafe()
Like
IControl.getValue() this returns the value of the component, but this returns null
if the value was invalid. |
boolean |
hasError()
Return T if this node currently has an error associated with it.
|
void |
immediate() |
void |
immediate(boolean immediate) |
boolean |
isChecked() |
boolean |
isDisabled()
Returns T if the control is currently in disabled.
|
boolean |
isImmediate() |
boolean |
isMandatory()
Returns T if this control is a mandatory input.
|
boolean |
isModified()
Returns the modified-by-user flag.
|
boolean |
isReadOnly()
Checkboxes cannot be readonly; we make them disabled instead.
|
void |
setChecked(boolean checked) |
void |
setDisabled(boolean disabled)
Set the input to disabled mode.
|
void |
setDisabledBecause(String msg) |
void |
setMandatory(boolean mandatory)
Make the control mandatory.
|
void |
setModified(boolean as)
Set or clear the modified by user flag.
|
void |
setOnValueChanged(IValueChanged<?> onValueChanged)
Deprecated.
|
void |
setReadOnly(boolean readOnly)
Sets the input to readonly-mode.
|
void |
setValue(Boolean v)
Set a new value into this control.
|
void |
visit(INodeVisitor v)
This must visit the appropriate method in the node visitor.
|
$, addBinding, addCssClass, addGlobalMessage, addNotificationListener, afterCreateContent, alignToLeft, alignToLeft, alignToMiddle, alignToMiddle, alignTopToBottom, alignTopToBottom, alignToRight, alignToRight, alignToTop, alignToTop, appendAfterMe, appendBeforeMe, appendCreateJS, appendJavascript, appendJQuerySelector, appendJsCustomUpdatesContributor, appendShowOverflowTextAsTitleJs, appendStatement, appendTreeErrors, beforeCreateContent, bind, bind, bindErrors, build, calcTestID, changed, changedJavascriptState, clearFocusRequested, clearGlobalMessage, clearGlobalMessage, clearGlobalMessage, clearMessage, clearValidationFailure, componentHandleWebAction, componentHandleWebDataRequest, createContent, createStatement, findComponentBundle, findParent, forceRebuild, getActualID, getAllocationTracepoint, getBindingErrors, getBindingList, getBrowserWindowSize, getCalculatedTestID, getClicked, getClientBounds, getComponentBundle, getComponentDataURL, getComponentDataURL, getComponentInfo, getComponentJSONURL, getCreateJS, getCssClass, getErrorList, getErrorLocation, getFocusID, getMessage, getOnClickJS, getOnMouseDownJS, getOnSizeAndPositionChange, getPage, getParent, getParent, getParent, getParentOfTypes, getSharedContext, getSharedContextFactory, getSpecialAttribute, getSpecialAttributeList, getTag, getTestID, getTestRepeatId, getThemedResourceRURL, getTitle, getUserObject, handleDrop, hasCssClass, hasParent, internalClearDelta, internalClearDeltaFully, internalCreateFrame, internalGetNodeCount, internalGetOldParent, internalGetParent, internalHasChangedAttributes, internalNeedClickHandler, internalOnBeforeRender, internalOnClicked, internalOnValueChanged, internalRenderJavascriptDelta, internalRenderJavascriptState, internalSetHasChangedAttributes, internalSetHasChangedAttributes, internalSetLogAllocations, internalSetTag, internalShelve, internalUnshelve, isAttached, isBuilt, isFocusable, isFocusRequested, isRendersOwnClose, isStretchHeight, lc, notify, notifyParentOrOpenerPage, onAddedToPage, onBeforeFullRender, onBeforeRender, onForceRebuild, onHeaderContributors, onRefresh, onRemoveFromPage, onShelve, onUnshelve, refresh, remove, removeBinding, removeCssClass, renderJavascriptDelta, renderJavascriptState, renderJavascriptState, replaceWith, setBrowserWindowSize, setCalculcatedId, setCalculcatedId, setClicked, setClientBounds, setComponentBundle, setCssClass, setErrorLocation, setFocus, setMessage, setOnClickJS, setOnMouseDownJS, setOnSizeAndPositionChange, setOverrideTitle, setSpecialAttribute, setStretchHeight, setTestID, setTestRepeatID, setTitle, setUserObject, toStringgetBackgroundAttachment, getBackgroundColor, getBackgroundImage, getBackgroundPosition, getBackgroundRepeat, getBorderBottomColor, getBorderBottomStyle, getBorderBottomWidth, getBorderLeftColor, getBorderLeftStyle, getBorderLeftWidth, getBorderRightColor, getBorderRightStyle, getBorderRightWidth, getBorderTopColor, getBorderTopStyle, getBorderTopWidth, getBottom, getCachedStyle, getClear, getColor, getDisplay, getFloat, getFontFamily, getFontSize, getFontSizeAdjust, getFontStyle, getFontVariant, getFontWeight, getHeight, getLeft, getLineHeight, getMarginBottom, getMarginLeft, getMarginRight, getMarginTop, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getOverflow, getPaddingBottom, getPaddingLeft, getPaddingRight, getPaddingTop, getPosition, getRight, getTextAlign, getTop, getTransform, getVerticalAlign, getVisibility, getWidth, getZIndex, internalSetDisplay, setBackgroundAttachment, setBackgroundColor, setBackgroundImage, setBackgroundPosition, setBackgroundRepeat, setBorder, setBorder, setBorderBottomColor, setBorderBottomStyle, setBorderBottomWidth, setBorderColor, setBorderLeftColor, setBorderLeftStyle, setBorderLeftWidth, setBorderRightColor, setBorderRightStyle, setBorderRightWidth, setBorderStyle, setBorderTopColor, setBorderTopStyle, setBorderTopWidth, setBorderWidth, setBottom, setBottom, setCachedStyle, setClear, setColor, setDisplay, setFloat, setFontFamily, setFontSize, setFontSizeAdjust, setFontStyle, setFontVariant, setFontWeight, setHeight, setLeft, setLeft, setLineHeight, setMargin, setMarginBottom, setMarginLeft, setMarginRight, setMarginTop, setMaxHeight, setMaxWidth, setMinHeight, setMinWidth, setOverflow, setPadding, setPaddingBottom, setPaddingLeft, setPaddingRight, setPaddingTop, setPosition, setRight, setRight, setTextAlign, setTop, setTop, setTransform, setVerticalAlign, setVisibility, setWidth, setZIndexclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetErrorLocation, setErrorLocationsetTestIDclearMessage, getMessage, setMessagepublic static final String TYPE_HINT
public void visit(INodeVisitor v) throws Exception
NodeBasepublic boolean isChecked()
public void setChecked(boolean checked)
public boolean isDisabled()
IControlisDisabled in interface IControl<Boolean>public void setDisabled(boolean disabled)
IActionControlsetDisabled in interface IActionControlpublic boolean isReadOnly()
isReadOnly in interface IControl<Boolean>IControl.isReadOnly()public void setReadOnly(boolean readOnly)
IControlsetReadOnly in interface IControl<Boolean>public boolean acceptRequestParameter(@Nonnull String[] values)
acceptRequestParameter in class NodeBase@Nonnull public Boolean getValue()
IControlValidationException. This means that this
call either delivers correct input (as defined by it's converter and validators), null
(when empty) or throws an exception. When a ValidationException occurs the framework
mostly ignores it - it does not produce a stacktrace or error in the client. Instead
the resulting error as posted by the error handling framework gets displayed on the
form when the request completes.
To get the value of a component while ignoring exceptions call IControl.getValueSafe().
getValue in interface IControl<Boolean>IControl.getValue()public void setValue(@Nullable Boolean v)
IControlsetValue in interface IControl<Boolean>IControl.setValue(java.lang.Object)public Boolean getValueSafe()
IControlIControl.getValue() this returns the value of the component, but this returns null
if the value was invalid. For this method NULL either means the value was invalid OR
it's content was empty. To distinguish between the two call IControl.hasError() or use
IControl.getValue() instead of this call.getValueSafe in interface IControl<Boolean>IControl.getValueSafe()public boolean hasError()
NodeBasepublic boolean isMandatory()
IControlisMandatory in interface IControl<Boolean>public void setMandatory(boolean mandatory)
IControlsetMandatory in interface IControl<Boolean>@Deprecated public IValueChanged<?> getOnValueChanged()
NodeBase.setClicked(IClickBase) to handle checkbox
change events!getOnValueChanged in interface IHasChangeListenergetOnValueChanged in interface INativeChangeListenerIHasChangeListener.getOnValueChanged()@Deprecated public void setOnValueChanged(IValueChanged<?> onValueChanged)
NodeBase.setClicked(IClickBase) to handle checkbox
change events!setOnValueChanged in interface IHasChangeListenerIHasChangeListener.setOnValueChanged(to.etc.domui.dom.html.IValueChanged)public boolean isModified()
isModified in interface IHasModifiedIndicationIHasModifiedIndication.isModified()public void setModified(boolean as)
setModified in interface IHasModifiedIndicationIHasModifiedIndication.setModified(boolean)public boolean isImmediate()
public void immediate(boolean immediate)
public void immediate()
Copyright © 2017 etc.to. All rights reserved.