Class JStringListField

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible

public class JStringListField extends JPanel
This class represents a component that stores list of strings and allows to edit them using ListEditorDialog.
See Also:
  • Constructor Details

    • JStringListField

      public JStringListField(Window parent, @Nullable Function<VTextField,Validator> validator)
      Sole constructor.
      Parameters:
      parent - The parent window that the editor dialog would be shown over.
      validator - Function that returns a validator for each list entry when editing them in the dialog, null means no validation.
  • Method Details

    • setEnabled

      public void setEnabled(boolean b)
      Overrides:
      setEnabled in class JComponent
    • addChangeListener

      public void addChangeListener(ChangeListener listener)
      Parameters:
      listener - Listener object to be registered for listening to value changes of this component.
    • setUniqueEntries

      public JStringListField setUniqueEntries(boolean uniqueEntries)
      Parameters:
      uniqueEntries - Whether duplicate string entries in the list are forbidden.
      Returns:
      This field instance.
    • getTextList

      public List<String> getTextList()
      Returns:
      List of string entries stored in this component.
    • setTextList

      public void setTextList(Collection<String> newTextList)
      Parameters:
      newTextList - List of string entries to be stored in this component.