Package uk.ac.starlink.ttools.cone
Class JdbcConer
java.lang.Object
uk.ac.starlink.ttools.cone.JdbcConer
- All Implemented Interfaces:
Coner
Coner implementation which works by performing SELECT statements over a
JDBC database connection.
- Since:
- 15 Aug 2007
- Author:
- Mark Taylor
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
configureRadiusParam
(uk.ac.starlink.task.Environment env, uk.ac.starlink.task.Parameter<?> srParam) Provides this object with a chance to perform custom configuration on certain general cone search parameters.createSearcher
(uk.ac.starlink.task.Environment env, boolean bestOnly) Returns a searcher object which can perform the actual cone searches as configured by this object's parameters.getCoverage
(uk.ac.starlink.task.Environment env) Returns a coverage object suitable for use with the cone search service configured by this object's parameters.uk.ac.starlink.task.Parameter<?>[]
Returns any configuration parameters associated with this object.Returns the empty string.boolean
useDistanceFilter
(uk.ac.starlink.task.Environment env) Indicates whether the result table generated by the created ConeSearcher object should be subjected to additional filtering to ensure that only rows in the specified search radius are included in the final output.
-
Constructor Details
-
JdbcConer
public JdbcConer()Constructor.
-
-
Method Details
-
getSkySystem
Returns the empty string. No particular coordinate system is mandated by this object.- Specified by:
getSkySystem
in interfaceConer
- Returns:
- ecliptic coordinate system name
-
getParameters
public uk.ac.starlink.task.Parameter<?>[] getParameters()Description copied from interface:Coner
Returns any configuration parameters associated with this object.- Specified by:
getParameters
in interfaceConer
- Returns:
- parameter array
-
configureRadiusParam
public void configureRadiusParam(uk.ac.starlink.task.Environment env, uk.ac.starlink.task.Parameter<?> srParam) Description copied from interface:Coner
Provides this object with a chance to perform custom configuration on certain general cone search parameters. If no customisation is required, no action need be taken. This will be called during the parameter acquisition phase, before the relevant parameters have been interrogated. Since the execution environment is given however, it will not be called during automatic document generation.- Specified by:
configureRadiusParam
in interfaceConer
- Parameters:
env
- execution environmentsrParam
- search radius parameter
-
useDistanceFilter
public boolean useDistanceFilter(uk.ac.starlink.task.Environment env) Description copied from interface:Coner
Indicates whether the result table generated by the created ConeSearcher object should be subjected to additional filtering to ensure that only rows in the specified search radius are included in the final output.- Specified by:
useDistanceFilter
in interfaceConer
- Parameters:
env
- execution environment- Returns:
- true iff post-query filtering on distance is to be performed
-
createSearcher
public ConeSearcher createSearcher(uk.ac.starlink.task.Environment env, boolean bestOnly) throws uk.ac.starlink.task.TaskException Description copied from interface:Coner
Returns a searcher object which can perform the actual cone searches as configured by this object's parameters. If thebestOnly
flag is set, then only the best match is required. The implementation may use this as a hint if it helps efficiency, but is not obliged to return single-row tables, since extraneous rows will be filtered out later. Similarly any rows which do not actually match the given criteria will be filtered out later, so it is not an error to return too many rows.- Specified by:
createSearcher
in interfaceConer
- Parameters:
env
- execution environmentbestOnly
- true iff only the best match will be used- Throws:
uk.ac.starlink.task.TaskException
-
getCoverage
Description copied from interface:Coner
Returns a coverage object suitable for use with the cone search service configured by this object's parameters.- Specified by:
getCoverage
in interfaceConer
- Parameters:
env
- execution environment- Returns:
- coverage footprint, or null
-