JSpinner is a component that contains a text field and two small buttons on the side. When the buttons are clicked, the text field value is incremented or decremented (see Figure 6.38).
The values in the spinner can be numbers, dates, values from a list, or, in the most general case, any sequence of values for which predecessors and successors can be determined. The
JSpinner class defines standard data models for the first three cases. You can define your own data model to describe arbitrary sequences.
By default, a spinner manages an integer, and the buttons ...