uk.ac.starlink.topcat.vizier
Class BasicVizierMode

java.lang.Object
  extended by uk.ac.starlink.topcat.vizier.BasicVizierMode
All Implemented Interfaces:
VizierMode
Direct Known Subclasses:
MissionVizierMode, SurveyVizierMode

public abstract class BasicVizierMode
extends Object
implements VizierMode

Abstract Vizier mode which presents a pre-selected list of catalogues to query.

Since:
19 Oct 2009
Author:
Mark Taylor

Constructor Summary
BasicVizierMode(String name, List<? extends uk.ac.starlink.util.gui.ArrayTableColumn<? extends Queryable,?>> columns)
          Constructor.
 
Method Summary
 Component getComponent()
          Returns the graphical component containing user controls for this mode.
 String getName()
          Returns a name for this mode.
 JTable getQueryableTable()
          Returns a table whose rows represent VizieR catalogues.
 VizierInfo getVizierInfo()
          Returns the vizier info object.
protected abstract  Queryable[] loadQueryables()
          Provides the array of Queryable objects which represents the catalogues which can be searched by this mode.
 void readData()
          Perform whatever updating from the remote server is necessary to initialise the state of this component from the currently installed VizierInfo.
 void setVizierInfo(VizierInfo vizinfo)
          Sets the object which can query a VizieR server and store metadata.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BasicVizierMode

public BasicVizierMode(String name,
                       List<? extends uk.ac.starlink.util.gui.ArrayTableColumn<? extends Queryable,?>> columns)
Constructor.

Parameters:
name - mode name
columns - array of Queryable-based columns for catalogue display
Method Detail

setVizierInfo

public void setVizierInfo(VizierInfo vizinfo)
Description copied from interface: VizierMode
Sets the object which can query a VizieR server and store metadata. This method must be called before the mode is called upon to contact the server.

Specified by:
setVizierInfo in interface VizierMode
Parameters:
vizinfo - vizier search object

getVizierInfo

public VizierInfo getVizierInfo()
Returns the vizier info object.

Returns:
vizinfo

getComponent

public Component getComponent()
Description copied from interface: VizierMode
Returns the graphical component containing user controls for this mode.

Specified by:
getComponent in interface VizierMode
Returns:
component

getName

public String getName()
Description copied from interface: VizierMode
Returns a name for this mode.

Specified by:
getName in interface VizierMode
Returns:
name mode name

getQueryableTable

public JTable getQueryableTable()
Description copied from interface: VizierMode
Returns a table whose rows represent VizieR catalogues. The table's model must be a ArrayTableModel with items that are Queryables.

Specified by:
getQueryableTable in interface VizierMode
Returns:
table of queryable objects representing Vizier catalogues

readData

public void readData()
Description copied from interface: VizierMode
Perform whatever updating from the remote server is necessary to initialise the state of this component from the currently installed VizierInfo. This method is called from the event dispatch thread, but should work asynchronously so as not to block the GUI.

Specified by:
readData in interface VizierMode

loadQueryables

protected abstract Queryable[] loadQueryables()
Provides the array of Queryable objects which represents the catalogues which can be searched by this mode. The returned items must be compatible with the ArrayTableColumns used by this mode. This method is not called on the event dispatch thread.

Returns:
array of queryable catalogues


Copyright © 2003-2018 CCLRC: Council for the Central Laboratory of the Research Councils. All Rights Reserved.