Interface PropertySheet.Item

All Known Implementing Classes:
BeanProperty
Enclosing class:
PropertySheet

public static interface PropertySheet.Item
A wrapper interface for a single property to be displayed in a PropertySheet control.
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns a String representation of the category of the property.
    A String that will be shown to the user as a tooltip.
    Returns the display name of the property, which should be short (i.e.
    Optional<javafx.beans.value.ObservableValue<? extends Object>>
    Returns the underlying ObservableValue, where one exists, that the editor can monitor for changes.
    default Optional<Class<? extends PropertyEditor<?>>>
    Returns an Optional wrapping the class of the PropertyEditor that should be used for editing this item.
    Returns the class type of the property.
    Returns the current value of the property.
    default boolean
    Indicates whether the PropertySheet should allow editing of this property, or whether it is read-only.
    void
    Sets the current value of the property.
  • Method Details

    • getType

      Class<?> getType()
      Returns the class type of the property.
    • getCategory

      String getCategory()
      Returns a String representation of the category of the property. This is relevant when the PropertySheet mode property is set to PropertySheet.Mode.CATEGORY - as then all properties with the same category will be grouped together visually.
    • getName

      String getName()
      Returns the display name of the property, which should be short (i.e. less than two words). This is used to explain to the end user what the property represents and is displayed beside the PropertyEditor. If you need to explain more detail to the user, consider placing it in the getDescription().
    • getDescription

      String getDescription()
      A String that will be shown to the user as a tooltip. This allows for a longer form of detail than what is possible with the getName() method.
    • getValue

      Object getValue()
      Returns the current value of the property.
    • setValue

      void setValue(Object value)
      Sets the current value of the property.
    • getObservableValue

      Optional<javafx.beans.value.ObservableValue<? extends Object>> getObservableValue()
      Returns the underlying ObservableValue, where one exists, that the editor can monitor for changes.
    • getPropertyEditorClass

      default Optional<Class<? extends PropertyEditor<?>>> getPropertyEditorClass()
      Returns an Optional wrapping the class of the PropertyEditor that should be used for editing this item. The default implementation returns Optional.empty() The class must have a constructor that can accept a single argument of type PropertySheet.Item
    • isEditable

      default boolean isEditable()
      Indicates whether the PropertySheet should allow editing of this property, or whether it is read-only. The default implementation returns true.