Class LoadXmlThrottlesLayoutAction

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

    public class LoadXmlThrottlesLayoutAction
    extends javax.swing.AbstractAction
    Load throttles from XML
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field Description
      (package private) javax.swing.JFileChooser fileChooser  
      • 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
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void actionPerformed​(java.awt.event.ActionEvent e)
      The action is performed.
      boolean loadThrottlesLayout​(java.io.File f)
      Parse the XML file and create ThrottleFrames.
      • Methods inherited from class javax.swing.AbstractAction

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

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

        accept
    • Method Detail

      • actionPerformed

        public void actionPerformed​(java.awt.event.ActionEvent e)
        The action is performed. Let the user choose the file to load from. Read XML for each ThrottleFrame.
        Parameters:
        e - The event causing the action.
      • loadThrottlesLayout

        public boolean loadThrottlesLayout​(java.io.File f)
                                    throws java.io.IOException
        Parse the XML file and create ThrottleFrames.
        Parameters:
        f - The XML file containing throttles.
        Returns:
        true if throttle loaded successfully, else false.
        Throws:
        java.io.IOException - on error.