GeoConvert Class

Summary: Converts coordinates to/from the different formats.

Module: aspose.gis

Full Name: aspose.gis.GeoConvert

Aspose.PSD Version: 25.9.0

Methods

NameDescription
as_point_text(latitude, longitude, format)Returns the calculated position as a string in the specified format.
as_point_text(point, format)Returns the calculated position as a string in the specified format.
parse_point_text(text)Converts the string that contains сoordinates to IPoint object.
try_parse_point_text(text, point)Converts the string that contains сoordinates to IPoint object. A return value indicates whether the conversion succeeded or failed.

Method: as_point_text(latitude, longitude, format) [static]

 as_point_text(latitude, longitude, format) 

Returns the calculated position as a string in the specified format.

Parameters:

ParameterTypeDescription
latitudedoublePosition latitude.
longitudedoublePosition longitude.
formatPointFormatsFormat of the result.

Returns

TypeDescription
stringPosition as string.

Method: as_point_text(point, format) [static]

 as_point_text(point, format) 

Returns the calculated position as a string in the specified format.

Parameters:

ParameterTypeDescription
pointIPointIPoint object.
formatPointFormatsFormat of the result.

Returns

TypeDescription
stringPosition as string.

Method: parse_point_text(text) [static]

 parse_point_text(text) 

Converts the string that contains сoordinates to IPoint object.

Parameters:

ParameterTypeDescription
textstringA string that contains coordinates to convert.
The string should contain both coordinate latitude and longitude.
Coordinates should be separated by whitespace, by comma or by semicolon.

Returns

TypeDescription
IPointIPoint object with coordinates that are equivalent to the input string.

Method: try_parse_point_text(text, point) [static]

 try_parse_point_text(text, point) 

Converts the string that contains сoordinates to IPoint object. A return value indicates whether the conversion succeeded or failed.

Parameters:

ParameterTypeDescription
textstringA string that contains coordinates to convert.
The string should contain both coordinate latitude and longitude.
Coordinates should be separated by whitespace, by comma or by semicolon.
pointIPoint[]When this method returns, contains the IPoint object with parsed coordinates, if the conversion succeeded, or null if the conversion failed.

Returns

TypeDescription
boolTrue if text was parsed successfully, otherwise False.