public class SourceCoordinates
extends java.lang.Object
implements java.lang.Runnable
Constructor and Description |
---|
SourceCoordinates(java.lang.String s,
java.lang.String csn,
double equinox,
java.lang.String resolver)
Constructor
|
SourceCoordinates(java.lang.String lon,
java.lang.String lat,
java.lang.String coords) |
Modifier and Type | Method and Description |
---|---|
boolean |
convertToCoords()
convert user input string to coords
|
static SourceCoordinates |
factory(java.lang.String s,
java.lang.String csn,
double equinox,
java.lang.String resolver) |
static SourceCoordinates |
factory(java.lang.String lon,
java.lang.String lat,
java.lang.String coords) |
Position |
getPosition()
Get the position associated with these coordinates.
|
java.lang.String |
heasarcResolve()
Set up and send query to resolve source name
|
static void |
main(java.lang.String[] args)
Test functionality.
|
boolean |
parseCoords()
extract coordinates that match coordinate system of user patch
from query return
|
void |
run()
send query to resolve user input
|
public SourceCoordinates(java.lang.String s, java.lang.String csn, double equinox, java.lang.String resolver)
s
- text entered as coordinates or object namecsn
- name of coordinate systemequinox
- equinox of coordinate systemresolver
- resolver to be used to resolve object namepublic SourceCoordinates(java.lang.String lon, java.lang.String lat, java.lang.String coords) throws java.lang.IllegalArgumentException
java.lang.IllegalArgumentException
public static SourceCoordinates factory(java.lang.String s, java.lang.String csn, double equinox, java.lang.String resolver)
public static SourceCoordinates factory(java.lang.String lon, java.lang.String lat, java.lang.String coords)
public Position getPosition()
public boolean convertToCoords()
public void run()
run
in interface java.lang.Runnable
public boolean parseCoords()
public java.lang.String heasarcResolve()
public static void main(java.lang.String[] args) throws java.lang.Exception
java.lang.Exception