Module is.codion.swing.common.ui
Interface NumberSpinnerBuilder<T extends Number>
- All Superinterfaces:
ComponentBuilder<T,
,JSpinner, NumberSpinnerBuilder<T>> SpinnerBuilder<T,
NumberSpinnerBuilder<T>>
public interface NumberSpinnerBuilder<T extends Number>
extends SpinnerBuilder<T,NumberSpinnerBuilder<T>>
A builder for number based JSpinner
-
Field Summary
Fields inherited from interface is.codion.swing.common.ui.component.builder.ComponentBuilder
COMPONENT_VALUE, TRANSFER_FOCUS_ON_ENTER
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T extends Number>
NumberSpinnerBuilder<T>builder
(SpinnerNumberModel spinnerNumberModel, Class<T> valueClass) static <T extends Number>
NumberSpinnerBuilder<T>builder
(SpinnerNumberModel spinnerNumberModel, Class<T> valueClass, Value<T> linkedValue) commitOnValidEdit
(boolean commitOnValidEdit) decimalFormatPattern
(String decimalFormatPattern) groupingUsed
(boolean groupingUsed) Methods inherited from interface is.codion.swing.common.ui.component.builder.ComponentBuilder
background, border, build, build, buildValue, buildValue, clientProperty, componentListener, componentOrientation, consumer, enabled, enabled, focusable, focusCycleRoot, focusListener, font, foreground, keyEvent, keyListener, label, link, link, listener, maximumHeight, maximumSize, maximumWidth, minimumHeight, minimumSize, minimumWidth, mouseListener, mouseMotionListener, mouseWheelListener, onBuild, onBuildValue, onSetVisible, opaque, popupMenu, popupMenuControl, popupMenuControls, preferredHeight, preferredSize, preferredWidth, propertyChangeListener, propertyChangeListener, scrollPane, toolTipText, transferFocusOnEnter, transferHandler, validator, value, visible
Methods inherited from interface is.codion.swing.common.ui.component.spinner.SpinnerBuilder
columns, editable, horizontalAlignment, mouseWheelScrolling, mouseWheelScrollingReversed
-
Method Details
-
minimum
- Parameters:
minimum
- the minimum value- Returns:
- this builder instance
-
maximum
- Parameters:
maximum
- the maximum value- Returns:
- this builder instance
-
stepSize
- Parameters:
stepSize
- the step size- Returns:
- this builder instance
-
groupingUsed
- Parameters:
groupingUsed
- true if number format grouping should be used- Returns:
- this builder instance
-
decimalFormatPattern
- Parameters:
decimalFormatPattern
- the decimal format pattern- Returns:
- this builder instance
-
commitOnValidEdit
- Parameters:
commitOnValidEdit
- true if the spinner should commit on a valid edit- Returns:
- this builder instance
- See Also:
-
builder
static <T extends Number> NumberSpinnerBuilder<T> builder(SpinnerNumberModel spinnerNumberModel, Class<T> valueClass) - Type Parameters:
T
- the number type- Parameters:
spinnerNumberModel
- the spinner modelvalueClass
- the value class- Returns:
- a new
NumberSpinnerBuilder
instance
-
builder
static <T extends Number> NumberSpinnerBuilder<T> builder(SpinnerNumberModel spinnerNumberModel, Class<T> valueClass, Value<T> linkedValue) - Type Parameters:
T
- the number type- Parameters:
spinnerNumberModel
- the spinner modelvalueClass
- the value classlinkedValue
- the value to link to- Returns:
- a new
NumberSpinnerBuilder
instance
-