Package uk.ac.starlink.vo
Class KeywordServiceQueryFactory
java.lang.Object
uk.ac.starlink.vo.KeywordServiceQueryFactory
- All Implemented Interfaces:
RegistryQueryFactory
RegistryQueryFactory implementation which combines a fixed base query
for a particular service type with a freeform keyword search.
- Since:
- 19 Dec 2008
- Author:
- Mark Taylor
-
Constructor Summary
ConstructorsConstructorDescriptionKeywordServiceQueryFactory
(Capability capability) Constructs a query factory which looks for services with a particular standard ID. -
Method Summary
Modifier and TypeMethodDescriptionvoid
addEntryListener
(ActionListener listener) Adds a listener which will be notified when the user has entered a query.May return a component which the user can interact with to select a query.getIdListQuery
(String[] ivoids) Returns a registry query suitable for this query factory which queries a given list of IVO identifiers.getQuery()
Returns the currently selected query.Returns the registry component object associated with this object.void
removeEntryListener
(ActionListener listener) Removes a listener previously added byRegistryQueryFactory.addEntryListener(java.awt.event.ActionListener)
.
-
Constructor Details
-
KeywordServiceQueryFactory
Constructs a query factory which looks for services with a particular standard ID.- Parameters:
capability
- description of capability which all results must have
-
-
Method Details
-
getQuery
Description copied from interface:RegistryQueryFactory
Returns the currently selected query.- Specified by:
getQuery
in interfaceRegistryQueryFactory
- Returns:
- query object
- Throws:
MalformedURLException
-
getIdListQuery
Description copied from interface:RegistryQueryFactory
Returns a registry query suitable for this query factory which queries a given list of IVO identifiers.- Specified by:
getIdListQuery
in interfaceRegistryQueryFactory
- Parameters:
ivoids
- ivo:-type resource identifiers- Returns:
- registry query whose results are suitable for a result of this query factory; may be null
- Throws:
MalformedURLException
-
getComponent
Description copied from interface:RegistryQueryFactory
May return a component which the user can interact with to select a query. If it returns null, this factory is considered to be non-interactive (only capable of supplying a single fixed query).- Specified by:
getComponent
in interfaceRegistryQueryFactory
- Returns:
- GUI component for query selection, or null
-
addEntryListener
Description copied from interface:RegistryQueryFactory
Adds a listener which will be notified when the user has entered a query.- Specified by:
addEntryListener
in interfaceRegistryQueryFactory
- Parameters:
listener
- listener
-
removeEntryListener
Description copied from interface:RegistryQueryFactory
Removes a listener previously added byRegistryQueryFactory.addEntryListener(java.awt.event.ActionListener)
.- Specified by:
removeEntryListener
in interfaceRegistryQueryFactory
- Parameters:
listener
- listener
-
getRegistrySelector
Description copied from interface:RegistryQueryFactory
Returns the registry component object associated with this object.- Specified by:
getRegistrySelector
in interfaceRegistryQueryFactory
- Returns:
- registry selector
-