if (queryArgs.getRegion() != null || sc == null || sc.length == 0) {
return;
}
// get the center position
WorldCoords wcs;
String objectName = (String) queryArgs.getParamValue(OBJECT);
if (objectName == null || objectName.length() == 0) {
// no object name specified, check RA and Dec
String raStr = (String) queryArgs.getParamValue(RA);
String decStr = (String) queryArgs.getParamValue(DEC);
if (raStr == null || decStr == null) {
return;
}
double equinox = _getEquinox(queryArgs);
wcs = new WorldCoords(raStr, decStr, equinox, true);
} else {
// an object name was specified, which needs to be resolved with a nameserver
Object o = queryArgs.getParamValue(NAME_SERVER);
if (!(o instanceof Catalog)) {
throw new RuntimeException("No name server was specified");
}
wcs = _resolveObjectName(objectName, (Catalog) o);
queryArgs.setParamValue(RA, wcs.getRA().toString());
queryArgs.setParamValue(DEC, wcs.getDec().toString());
queryArgs.setParamValue(EQUINOX, "2000");
}
// look for a min and max radius, or width and height parameters
// See corresponding code in _initSearchParameters().