Class NumericParameterControl<T extends Number & Comparable<T>>

  • Type Parameters:
    T - The numeric type of this control (e.g. Integer, Double).
    All Implemented Interfaces:
    EvolutionControl

    public class NumericParameterControl<T extends Number & Comparable<T>>
    extends Object
    implements EvolutionControl
    A GUI control that allows the user to set/update the value of a numeric parameter.
    • Constructor Detail

      • NumericParameterControl

        public NumericParameterControl​(T minimum,
                                       T maximum,
                                       T stepSize,
                                       T initialValue)
    • Method Detail

      • reset

        public void reset()
        Resets the control to its initial configuration.
        Specified by:
        reset in interface EvolutionControl
      • getNumberGenerator

        public NumberGenerator<T> getNumberGenerator()
        Returns a number generator that simply returns the current value contained in the spinner field.
        Returns:
        A number generator that can be used to control an evolutionary program.
      • setDescription

        public void setDescription​(String description)
        Provides a textual description of the purpose of the control. This may be displayed somewhere on the GUI component (typically as tooltip text).
        Specified by:
        setDescription in interface EvolutionControl
        Parameters:
        description - The description of the control.