logger.error("Unable to get a geometry from the node");
throw new XPathException("Unable to get a geometry from the node");
}
//Transform the geometry to EPSG:4326 if relevant
if (propertyName.indexOf("EPSG4326") != Constants.STRING_NOT_FOUND) {
geometry = indexWorker.transformGeometry(geometry, sourceCRS, "EPSG:4326");
if (isCalledAs("getEPSG4326WKT")) {
result = new StringValue(wktWriter.write(geometry));
} else if (isCalledAs("getEPSG4326WKB")) {
byte data[] = wkbWriter.write(geometry);
return BinaryValueFromInputStream.getInstance(context, new Base64BinaryValueType(), new ByteArrayInputStream(data));