Class FileHistoryAction

  • All Implemented Interfaces:
    java.awt.event.ActionListener, java.io.Serializable, java.lang.Cloneable, java.util.EventListener, javax.swing.Action

    public class FileHistoryAction
    extends javax.swing.AbstractAction
    The action for loading files from the history in the file menu.
    Version:
    1.0
    Author:
    Andreas
    See Also:
    Serialized Form
    • Field Summary

      • Fields inherited from class javax.swing.AbstractAction

        changeSupport, enabled
      • Fields inherited from interface javax.swing.Action

        ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
    • Constructor Summary

      Constructors 
      Constructor Description
      FileHistoryAction​(FileHistory hist, java.io.File cr)
      Creates a new FileHistoryAction object.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void actionPerformed​(java.awt.event.ActionEvent e)
      Loads the file that was selected.
      boolean equals​(java.lang.Object o)
      Two actions are equal if their files are equal.
      java.io.File getFile()
      Returns the associated file.
      int hashCode()  
      • Methods inherited from class javax.swing.AbstractAction

        addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
      • Methods inherited from class java.lang.Object

        finalize, getClass, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface javax.swing.Action

        accept
    • Constructor Detail

      • FileHistoryAction

        public FileHistoryAction​(FileHistory hist,
                                 java.io.File cr)
        Creates a new FileHistoryAction object.
    • Method Detail

      • actionPerformed

        public void actionPerformed​(java.awt.event.ActionEvent e)
        Loads the file that was selected.
        See Also:
        ActionListener.actionPerformed(java.awt.event.ActionEvent)
      • getFile

        public java.io.File getFile()
        Returns the associated file.
      • equals

        public boolean equals​(java.lang.Object o)
        Two actions are equal if their files are equal.
        Overrides:
        equals in class java.lang.Object
        See Also:
        Object.equals(java.lang.Object)
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object