Class LoadWindow

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, RootPaneContainer, WindowConstants

public class LoadWindow extends AuxWindow
Window which displays the main gui from which to load tables into the application. It contains toolbar buttons etc for different individual load dialogues.
See Also:
  • Field Details

    • LOAD_DIALOGS_PROPERTY

      public static final String LOAD_DIALOGS_PROPERTY
      Name of the system property which can be used to specify the class names of additional TableLoadDialog implementations. Each must have a no-arg constructor. Multiple classnames should be separated by colons.
      See Also:
    • DIALOG_CLASSES

      public final String[] DIALOG_CLASSES
      Class names for the TableLoadDialogs known by default.
  • Constructor Details

    • LoadWindow

      public LoadWindow(Component parent, uk.ac.starlink.table.StarTableFactory tfact)
      Constructor.
      Parameters:
      parent - parent component
      tfact - table factory
  • Method Details

    • getKnownDialogs

      public uk.ac.starlink.table.gui.TableLoadDialog[] getKnownDialogs()
      Returns list of dialogues known by this window.
      Returns:
      dialogue list
    • getKnownDialog

      public uk.ac.starlink.table.gui.TableLoadDialog getKnownDialog(Class<? extends uk.ac.starlink.table.gui.TableLoadDialog> clazz)
      Returns a TableLoadDialog in the list known by this window which has a given class.
      Parameters:
      clazz - class, some subclass of TableLoadDialog
      Returns:
      existing dialog instance of clazz, or null
    • getDialogAction

      public Action getDialogAction(Class<? extends uk.ac.starlink.table.gui.TableLoadDialog> tldClazz)
      Returns the action associated with a TableLoadDialog of a given class, if one is currently in use by this window.
      Parameters:
      tldClazz - class, some subclass of TableLoadDialog
      Returns:
      action which invokes an instance of tldClazz, if one is in use
    • isShowing

      public boolean isShowing(uk.ac.starlink.table.gui.TableLoadDialog tld)
      Indicates whether a given load dialogue controlled by this window is currently visible.
      Parameters:
      tld - dialogue
      Returns:
      true iff a window containing tld's query component is currently showing
    • addWorker

      public void addWorker(uk.ac.starlink.table.gui.TableLoadWorker worker, Icon icon)
      Adds a thread which is loading a table to the display in this window.
      Parameters:
      worker - loading thread
      icon - optional icon indicatig table source
    • removeWorker

      public void removeWorker(uk.ac.starlink.table.gui.TableLoadWorker worker)
      Removes a load worker thread which was previously added to the display in this window.
      Parameters:
      worker - loading thread
    • conditionallyClose

      public void conditionallyClose()
      Indicates that an activity has finished which might cause this window to close. This may or may not cause the window to close, depending on its internal state.