Package uk.ac.starlink.vo
Class RegistryServiceTableLoadDialog
- java.lang.Object
-
- uk.ac.starlink.table.gui.AbstractTableLoadDialog
-
- uk.ac.starlink.vo.RegistryServiceTableLoadDialog
-
- All Implemented Interfaces:
uk.ac.starlink.table.gui.TableLoadDialog
- Direct Known Subclasses:
DalTableLoadDialog
public abstract class RegistryServiceTableLoadDialog extends uk.ac.starlink.table.gui.AbstractTableLoadDialogPartial implementation of a table load dialogue which has two parts: first a query on the registry to locate a set of suitable services, and then a query to one of the services selected from that list. Concrete subclasses should populate the control boxgetControlBox()with service-specific controls and implement the abstractTableLoadDialog.createTableLoader()method appropriately.- Since:
- 6 Jan 2005
- Author:
- Mark Taylor (Starlink)
-
-
Constructor Summary
Constructors Constructor Description RegistryServiceTableLoadDialog(java.lang.String name, java.lang.String protoName, java.lang.String description, RegistryQueryFactory queryFactory, boolean showCapabilities)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanacceptResourceIdList(java.lang.String[] ivoids, java.lang.String msg)Takes a list of resource ID values and may load them or a subset into this object's dialogue as appropriate.protected java.awt.ComponentcreateQueryComponent()RegCapabilityInterface[]getCapabilities(RegResource resource)Returns the capabilities associated with a given resource.protected javax.swing.JComponentgetControlBox()Returns the component within which service-specific components should be placed.RegistryQueryFactorygetQueryFactory()Returns the query factory used by this dialogue.javax.swing.JMenuItem[]getRegistryMenuItems()Returns a list of menu items for actions associated with this component.RegistryPanelgetRegistryPanel()Returns the registry panel for this dialogue.-
Methods inherited from class uk.ac.starlink.table.gui.AbstractTableLoadDialog
asIOException, configure, createFormatSelector, getDescription, getIcon, getMenus, getName, getQueryComponent, getSelectedFormat, getSubmitAction, getToolbarActions, isAvailable, isComponentShowing, isReady, setIcon, setIconUrl, setMenus, setToolbarActions, submit, updateReady
-
-
-
-
Constructor Detail
-
RegistryServiceTableLoadDialog
public RegistryServiceTableLoadDialog(java.lang.String name, java.lang.String protoName, java.lang.String description, RegistryQueryFactory queryFactory, boolean showCapabilities)Constructor.- Parameters:
name- dialogue nameprotoName- short name (perhaps acronym) for protocoldescription- dialogue descriptionqueryFactory- source of registry query definitionshowCapabilities- true to display the capabilities JTable as well as the Resource one; sensible if resource:capabilities relationship may not be 1:1
-
-
Method Detail
-
getRegistryMenuItems
public javax.swing.JMenuItem[] getRegistryMenuItems()
Returns a list of menu items for actions associated with this component.- Returns:
- registry menu item list
-
acceptResourceIdList
public boolean acceptResourceIdList(java.lang.String[] ivoids, java.lang.String msg)Takes a list of resource ID values and may load them or a subset into this object's dialogue as appropriate.- Parameters:
ivoids- ivo:-type identifier stringsmsg- text of user-directed message to explain where the IDs came from- Returns:
- true iff at least some of the resources were, or may be, loaded into this window
-
createQueryComponent
protected java.awt.Component createQueryComponent()
- Specified by:
createQueryComponentin classuk.ac.starlink.table.gui.AbstractTableLoadDialog
-
getControlBox
protected javax.swing.JComponent getControlBox()
Returns the component within which service-specific components should be placed. Will return null if called beforecreateQueryComponent().- Returns:
- control box
-
getRegistryPanel
public RegistryPanel getRegistryPanel()
Returns the registry panel for this dialogue. Will return null if called beforecreateQueryComponent().- Returns:
- registry panel
-
getCapabilities
public RegCapabilityInterface[] getCapabilities(RegResource resource)
Returns the capabilities associated with a given resource. This determines those capabilities which will be displayed and selecatable for each resource. The default implementation is to include all capabilities; this may however be overridded in a more selective way by subclasses.- Parameters:
resource- registry resource- Returns:
- relevant capabilities from that resource
-
getQueryFactory
public RegistryQueryFactory getQueryFactory()
Returns the query factory used by this dialogue.- Returns:
- query factory
-
-