Class TimePicker

  • All Implemented Interfaces:
    EventTarget

    public class TimePicker
    extends Dialog<LocalTime>

    A TimePicker is used to select a single time (hours:minutes). The selected time is indicated by the filled circle at the end of the clock hand.

    A user can select between minutes or hours selection by tapping the hour or minute label in the title bar, additionally he can also select between am or pm by tapping the respective label. When the user is finished selecting the time he can press the OK button.

    The TimePicker is a Dialog, for any further explanation on how dialogs work please refer to the Dialog documentation.

    Screenshot of TimePicker

    Since:
    2.0.0
    See Also:
    Dialog
    • Constructor Detail

      • TimePicker

        public TimePicker()
        Creates a TimePicker instance with the current time instant.
      • TimePicker

        public TimePicker​(LocalTime time)
        Creates a TimePicker instance with the specified time.
        Parameters:
        time - The time instant to set on this TimePicker
    • Method Detail

      • getTime

        public final LocalTime getTime()
        Gets the value of the property time.
        Property description:
        The time represented in this TimePicker.
      • setTime

        public final void setTime​(LocalTime value)
        Sets the value of the property time.
        Property description:
        The time represented in this TimePicker.