public class SliderImpl<V extends java.lang.Number> extends AbstractField<JmixSlider<V>,V,V> implements Slider<V>
HasValue.ValueChangeEvent<V>Component.Alignment, Component.BelongToFrame, Component.Disposable, Component.Editable, Component.Focusable, Component.HasCaption, Component.HasDescription, Component.HasIcon, Component.HasXmlDescriptor, Component.WrapperHasContextHelp.ContextHelpIconClickEventHasOrientation.Orientation| Modifier and Type | Field and Description |
|---|---|
protected DataAwareComponentsTools |
dataAwareComponentsTools |
protected io.jmix.core.metamodel.datatype.Datatype<V> |
datatype |
editable, parentEditableChangeListener, validators, VALIDATORS_LIST_INITIAL_CAPACITYinternalValue, uiTestIdsSupport, valueBindingalignment, applicationContext, component, contextHelpIconClickHandler, contextHelpIconClickListener, descriptionAsHtml, element, frame, htmlSanitizerEnabled, icon, ICON_STYLE, id, parentAUTO_SIZE, AUTO_SIZE_PX, FULL_SIZE| Constructor and Description |
|---|
SliderImpl() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
attachValueChangeListener(JmixSlider<V> component) |
protected void |
componentValueChanged(java.lang.Double prevComponentValue,
java.lang.Double newComponentValue,
boolean isUserOriginated) |
protected V |
convertFromDouble(java.lang.Double componentValue) |
protected java.lang.Double |
convertToDouble(V value) |
protected JmixSlider<V> |
createComponent() |
io.jmix.core.metamodel.datatype.Datatype<V> |
getDatatype() |
V |
getMax() |
V |
getMin() |
HasOrientation.Orientation |
getOrientation() |
int |
getResolution() |
boolean |
isUpdateValueOnCLick() |
protected io.jmix.core.metamodel.datatype.Datatype<V> |
loadDatatype() |
void |
setDataAwareComponentsTools(DataAwareComponentsTools dataAwareComponentsTools) |
void |
setDatatype(io.jmix.core.metamodel.datatype.Datatype<V> datatype)
Sets the given
datatype to the component. |
void |
setMax(V max)
Sets the maximum value of the slider.
|
void |
setMin(V min)
Sets the minimum value of the slider.
|
void |
setOrientation(HasOrientation.Orientation orientation) |
void |
setResolution(int resolution)
Sets the number of digits after the decimal point.
|
void |
setUpdateValueOnClick(boolean updateValueOnClick)
Sets the slider to update its value when the user clicks on it.
|
addValidator, getDatatypeConversionErrorMsg, getDefaultRequiredMessage, getErrorMessage, getRequiredMessage, getValidators, isEditable, isRequired, isValid, removeValidator, setEditable, setEditableToComponent, setParent, setRequired, setRequiredMessage, setupComponentErrorProvider, triggerValidators, validateaddValueChangeListener, commit, componentValueChanged, convertToModel, convertToPresentation, discard, fieldValueEquals, getValue, getValueSource, isBuffered, isModified, setBuffered, setUiTestId, setUiTestIdsSupport, setValue, setValueSource, setValueToPresentation, valueBindingActivated, valueBindingConnectedaddAttachListener, addDetachListener, addStyleName, assignDebugId, attached, detached, getAlignment, getCaption, getComponent, getComposition, getContextHelpIconClickHandler, getContextHelpText, getDebugId, getDescription, getEventHub, getFrame, getHeight, getHeightSizeUnit, getHtmlSanitizer, getIcon, getIconName, getIconResource, getId, getParent, getStyleName, getUiComponentProperties, getUiProperties, getWidth, getWidthSizeUnit, getXmlDescriptor, hasSubscriptions, hasValidationError, isAttached, isCaptionAsHtml, isContextHelpTextHtmlEnabled, isDescriptionAsHtml, isEnabled, isEnabledRecursive, isHtmlSanitizerEnabled, isResponsive, isVisible, isVisibleRecursive, onContextHelpIconClick, publish, removeStyleName, sanitize, setAlignment, setApplicationContext, setCaption, setCaptionAsHtml, setContextHelpIconClickHandler, setContextHelpText, setContextHelpTextHtmlEnabled, setDebugId, setDescription, setDescriptionAsHtml, setEnabled, setFrame, setHeight, setHtmlSanitizerEnabled, setIcon, setIconFromSet, setId, setResponsive, setStyleName, setValidationError, setVisible, setWidth, setXmlDescriptor, unsubscribe, unwrap, unwrapComposition, unwrapCompositionOrNull, unwrapOrNull, withUnwrapped, withUnwrappedCompositionclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetValueSource, setValueSourceaddValueChangeListener, clear, getEmptyValue, getValue, isEmpty, setValueisEditable, isEditableWithParent, setEditablegetFrame, setFrameaddStyleName, getAlignment, getHeight, getHeightSizeUnit, getId, getParent, getStyleName, getWidth, getWidthSizeUnit, isEnabled, isEnabledRecursive, isResponsive, isVisible, isVisibleRecursive, removeStyleName, setAlignment, setEnabled, setHeight, setHeightAuto, setHeightFull, setId, setParent, setResponsive, setSizeAuto, setSizeFull, setStyleName, setVisible, setWidth, setWidthAuto, setWidthFull, unwrap, unwrapComposition, unwrapCompositionOrNull, unwrapOrNull, withUnwrapped, withUnwrappedCompositionisValid, isValidateOnCommit, validategetIcon, setIcon, setIconFromSetgetContextHelpIconClickHandler, getContextHelpText, isContextHelpTextHtmlEnabled, setContextHelpIconClickHandler, setContextHelpText, setContextHelpTextHtmlEnabledisCaptionAsHtml, setCaptionAsHtmlgetCaption, setCaptiongetDescription, setDescriptionisDescriptionAsHtml, setDescriptionAsHtmlisHtmlSanitizerEnabled, setHtmlSanitizerEnabledaddValidator, addValidators, getValidators, removeValidatorgetRequiredMessage, isRequired, setRequired, setRequiredMessageprotected io.jmix.core.metamodel.datatype.Datatype<V extends java.lang.Number> datatype
protected DataAwareComponentsTools dataAwareComponentsTools
protected JmixSlider<V> createComponent()
@Autowired public void setDataAwareComponentsTools(DataAwareComponentsTools dataAwareComponentsTools)
public void setMin(V min)
Sliderpublic V getMin()
public void setMax(V max)
Sliderpublic V getMax()
public void setResolution(int resolution)
SlidersetResolution in interface Slider<V extends java.lang.Number>resolution - the number of digits after the decimal pointpublic int getResolution()
getResolution in interface Slider<V extends java.lang.Number>public void setUpdateValueOnClick(boolean updateValueOnClick)
SliderBy default this behavior is disabled.
setUpdateValueOnClick in interface Slider<V extends java.lang.Number>updateValueOnClick - true to update the value of the slider on clickpublic boolean isUpdateValueOnCLick()
isUpdateValueOnCLick in interface Slider<V extends java.lang.Number>true if the slider updates its value on clickpublic HasOrientation.Orientation getOrientation()
getOrientation in interface HasOrientationpublic void setOrientation(HasOrientation.Orientation orientation)
setOrientation in interface HasOrientation@Nullable public io.jmix.core.metamodel.datatype.Datatype<V> getDatatype()
getDatatype in interface HasDatatype<V extends java.lang.Number>public void setDatatype(io.jmix.core.metamodel.datatype.Datatype<V> datatype)
HasDatatypedatatype to the component. Its value will be formatted according to this
datatype.setDatatype in interface HasDatatype<V extends java.lang.Number>datatype - Datatype instanceprotected io.jmix.core.metamodel.datatype.Datatype<V> loadDatatype()
protected void attachValueChangeListener(JmixSlider<V> component)
attachValueChangeListener in class AbstractField<JmixSlider<V extends java.lang.Number>,V extends java.lang.Number,V extends java.lang.Number>protected void componentValueChanged(java.lang.Double prevComponentValue,
java.lang.Double newComponentValue,
boolean isUserOriginated)
protected V convertFromDouble(java.lang.Double componentValue) throws ConversionException
ConversionExceptionprotected java.lang.Double convertToDouble(V value)