I have a Java
program in which I use an object type that stores the puntos cardinales
of a place (north, south, east and west) and I need to transform it into latitud
and longitud
.
How can I do it? Do I need an external library?
Thanks in advance
UPDATE
I receive this information, and from it I have to get a point:
"geometry": [{"north": 74.4, "south": 32.6, "west": 26.0, "east": 42.4}]}
With them I need to generate a POINT (long, lat)
UPDATE 2
I can also get this information in POLYGON format:
areaOfInterest": "POLYGON((7.67798 45.11909,7.60176 45.06504,7.66047 45.00936,7.70476 45.06285,7.736 45.10067,7.67798 45.11909))"
Is it possible from this POLYGON to obtain a POINT like the following?
"location": "POINT(7.6567492 45.0651474)"