Package uk.ac.starlink.ttools.cone
Interface Coverage
- All Known Implementing Classes:
ConeQueryCoverage
,MocCoverage
,UrlMocCoverage
public interface Coverage
Defines coverage of a sky positional search service.
- Since:
- 16 Dec 2011
- Author:
- Mark Taylor
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionboolean
discOverlaps
(double alphaDeg, double deltaDeg, double radiusDeg) Indicates whether a given disc on the sphere overlaps, or may overlap with this coverage.Returns the amount category for coverage.void
Must be called before any of the query methods are used.
-
Method Details
-
initCoverage
Must be called before any of the query methods are used. May be time consuming (it may contact an external service). It is legal to call this method multiple times from the same or different threads. IfgetAmount()
returns non-null, this method will return directly. Following a successful or error return of this method,getAmount()
will return non-null.- Throws:
IOException
-
getAmount
Coverage.Amount getAmount()Returns the amount category for coverage. If the footprint is not ready for use, null is returned. In that case,initCoverage()
must be called before use.- Returns:
- coverage amount category
-
discOverlaps
boolean discOverlaps(double alphaDeg, double deltaDeg, double radiusDeg) Indicates whether a given disc on the sphere overlaps, or may overlap with this coverage. False positives are permitted.- Parameters:
alphaDeg
- central longitude in degreesdeltaDeg
- central latitude in degreesradiusDeg
- radius in degrees- Returns:
- false if the given disc definitely does not overlap this footprint; otherwise true
- Throws:
IllegalStateException
- ifinitCoverage
has not been called
-