Package uk.ac.starlink.topcat.vizier
Class BasicVizierMode
- java.lang.Object
-
- uk.ac.starlink.topcat.vizier.BasicVizierMode
-
- All Implemented Interfaces:
VizierMode
- Direct Known Subclasses:
MissionVizierMode
,SurveyVizierMode
public abstract class BasicVizierMode extends java.lang.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
Constructors Constructor Description BasicVizierMode(java.lang.String name, java.util.List<? extends uk.ac.starlink.util.gui.ArrayTableColumn<? extends Queryable,?>> columns)
Constructor.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description java.awt.Component
getComponent()
Returns the graphical component containing user controls for this mode.java.lang.String
getName()
Returns a name for this mode.javax.swing.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.
-
-
-
Constructor Detail
-
BasicVizierMode
public BasicVizierMode(java.lang.String name, java.util.List<? extends uk.ac.starlink.util.gui.ArrayTableColumn<? extends Queryable,?>> columns)
Constructor.- Parameters:
name
- mode namecolumns
- 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 interfaceVizierMode
- Parameters:
vizinfo
- vizier search object
-
getVizierInfo
public VizierInfo getVizierInfo()
Returns the vizier info object.- Returns:
- vizinfo
-
getComponent
public java.awt.Component getComponent()
Description copied from interface:VizierMode
Returns the graphical component containing user controls for this mode.- Specified by:
getComponent
in interfaceVizierMode
- Returns:
- component
-
getName
public java.lang.String getName()
Description copied from interface:VizierMode
Returns a name for this mode.- Specified by:
getName
in interfaceVizierMode
- Returns:
- name mode name
-
getQueryableTable
public javax.swing.JTable getQueryableTable()
Description copied from interface:VizierMode
Returns a table whose rows represent VizieR catalogues. The table's model must be aArrayTableModel
with items that areQueryable
s.- Specified by:
getQueryableTable
in interfaceVizierMode
- 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 interfaceVizierMode
-
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 theArrayTableColumn
s used by this mode. This method is not called on the event dispatch thread.- Returns:
- array of queryable catalogues
-
-