Class DetailEditor

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable

public abstract class DetailEditor extends JComponent
A detail editor.
See Also:
  • Field Details

    • object

      private Object object
      The object, that is edited.
    • confirmed

      private boolean confirmed
      whether the edit process has been confirmed (user pressed OK).
  • Constructor Details

    • DetailEditor

      public DetailEditor()
      Creates a new editor.
  • Method Details

    • update

      public void update()
      Updates the object.
    • getObject

      public Object getObject()
      Returns the object.
      Returns:
      The object.
    • setObject

      public void setObject(Object object)
      Sets the object to be edited.
      Parameters:
      object - the object.
    • parseInt

      protected static int parseInt(String text, int def)
      Parses an integer.
      Parameters:
      text - the text.
      def - the default value.
      Returns:
      The parsed integer, or the default value if the string didn't contain a value.
    • clear

      public abstract void clear()
      Clears the editor.
    • fillObject

      protected abstract void fillObject()
      Edits the object. The object itself should not be modified, until update or create was called.
    • updateObject

      protected abstract void updateObject(Object object)
      Updates the object.
      Parameters:
      object - the object.
    • isConfirmed

      public boolean isConfirmed()
      Returns the confirmed flag.
      Returns:
      The confirmed flag.
    • setConfirmed

      protected void setConfirmed(boolean confirmed)
      Sets the confirmed flag.
      Parameters:
      confirmed - the confirmed flag.