Class VizierTableLoadDialog

  • All Implemented Interfaces:
    uk.ac.starlink.table.gui.TableLoadDialog

    public class VizierTableLoadDialog
    extends uk.ac.starlink.table.gui.AbstractTableLoadDialog
    TableLoadDialogue which directly interrogtes the VizieR catalogue service.
    Since:
    19 Oct 2009
    Author:
    Mark Taylor, Thomas Boch
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String[] SERVER_URLS
      URLs known to host a standard VizieR service.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addTargetActionListener​(java.awt.event.ActionListener listener)
      Adds a listener which will be notified when the user-selected target may change.
      void addTargetCaretListener​(javax.swing.event.CaretListener listener)
      Adds a listener which will be notified when the text entered in the user-selected target boxes may change.
      protected java.awt.Component createQueryComponent()  
      uk.ac.starlink.table.gui.TableLoader createTableLoader()  
      static java.lang.String encodeArg​(java.lang.String txt)
      Turns a text string into a string which can be appended to a URL to specify a value-less query argument.
      static java.lang.String encodeArg​(java.lang.String name, java.lang.String value)
      Turns a name, value pair into a string which can be appended to a URL to specify a query argument and its value.
      java.lang.String getRadius()
      Returns the radius string in degrees.
      java.lang.String getTarget()
      Returns the search target, as presented to the VizieR server's -c parameter.
      boolean hasTarget()
      Indicates whether enough information has been filled in by the user to specify a search on a given catalogue.
      boolean isAvailable()  
      boolean isReady()  
      void removeTargetActionListener​(java.awt.event.ActionListener listener)
      Removes a listener previously added by addTargetActionListener(java.awt.event.ActionListener).
      void removeTargetCaretListener​(javax.swing.event.CaretListener listener)
      Removes a listener previously added by addTargetCaretListener(javax.swing.event.CaretListener).
      • Methods inherited from class uk.ac.starlink.table.gui.AbstractTableLoadDialog

        asIOException, configure, createFormatSelector, getDescription, getIcon, getMenus, getName, getQueryComponent, getSelectedFormat, getSubmitAction, getToolbarActions, isComponentShowing, setIcon, setIconUrl, setMenus, setToolbarActions, submit, updateReady
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • SERVER_URLS

        public static final java.lang.String[] SERVER_URLS
        URLs known to host a standard VizieR service. This list is subject to change, but not very often. The definitive list is available from http://vizier.u-strasbg.fr/vizier/mirrors.gml.
    • Constructor Detail

      • VizierTableLoadDialog

        public VizierTableLoadDialog()
        Constructor.
    • Method Detail

      • createQueryComponent

        protected java.awt.Component createQueryComponent()
        Specified by:
        createQueryComponent in class uk.ac.starlink.table.gui.AbstractTableLoadDialog
      • isAvailable

        public boolean isAvailable()
        Specified by:
        isAvailable in interface uk.ac.starlink.table.gui.TableLoadDialog
        Overrides:
        isAvailable in class uk.ac.starlink.table.gui.AbstractTableLoadDialog
      • getTarget

        public java.lang.String getTarget()
        Returns the search target, as presented to the VizieR server's -c parameter.
        Returns:
        formatted target string; empty string for all rows
      • getRadius

        public java.lang.String getRadius()
        Returns the radius string in degrees.
        Returns:
        formatted radius string; empty string for all rows
      • createTableLoader

        public uk.ac.starlink.table.gui.TableLoader createTableLoader()
      • isReady

        public boolean isReady()
        Overrides:
        isReady in class uk.ac.starlink.table.gui.AbstractTableLoadDialog
      • hasTarget

        public boolean hasTarget()
        Indicates whether enough information has been filled in by the user to specify a search on a given catalogue.
        Returns:
        true if a queryable query can take place; false if more info needs to be entered
      • addTargetActionListener

        public void addTargetActionListener​(java.awt.event.ActionListener listener)
        Adds a listener which will be notified when the user-selected target may change.
        Parameters:
        listener - listener to add
      • addTargetCaretListener

        public void addTargetCaretListener​(javax.swing.event.CaretListener listener)
        Adds a listener which will be notified when the text entered in the user-selected target boxes may change.
        Parameters:
        listener - the listener to add
      • encodeArg

        public static java.lang.String encodeArg​(java.lang.String name,
                                                 java.lang.String value)
        Turns a name, value pair into a string which can be appended to a URL to specify a query argument and its value. An ampersand is prepended.
        Parameters:
        name - arg name
        value - arg value
        Returns:
        &name=value (properly encoded)
      • encodeArg

        public static java.lang.String encodeArg​(java.lang.String txt)
        Turns a text string into a string which can be appended to a URL to specify a value-less query argument. An ampersand is prepended.
        Parameters:
        txt - arg text
        Returns:
        &txt (properly encoded)