C# Class Spatial4n.Core.Io.ParseUtils

Utility methods related to parsing shapes.
Afficher le fichier Open project: synhershko/Spatial4n Class Usage Examples

Méthodes publiques

Méthode Description
ParseLatitudeLongitude ( String latLonStr ) : double[]
ParseLatitudeLongitude ( double latLon, String latLonStr ) : double[]

extract (by calling {@link #parsePoint(String[], String, int)} and validate the latitude and longitude contained in the String by making sure the latitude is between 90 & -90 and longitude is between -180 and 180.

The latitude is assumed to be the first part of the string and the longitude the second part.

ParsePoint ( String _out, String externalVal, int dimension ) : String[]

Given a string containing dimension values encoded in it, separated by commas, return a String array of length dimension containing the values.

ParsePointDouble ( double @out, String externalVal, int dimension ) : double[]

Given a string containing dimension values encoded in it, separated by commas, return a double array of length dimension containing the values.

Method Details

ParseLatitudeLongitude() public static méthode

public static ParseLatitudeLongitude ( String latLonStr ) : double[]
latLonStr String
Résultat double[]

ParseLatitudeLongitude() public static méthode

extract (by calling {@link #parsePoint(String[], String, int)} and validate the latitude and longitude contained in the String by making sure the latitude is between 90 & -90 and longitude is between -180 and 180.

The latitude is assumed to be the first part of the string and the longitude the second part.

public static ParseLatitudeLongitude ( double latLon, String latLonStr ) : double[]
latLon double A preallocated array to hold the result
latLonStr String The string to parse. Latitude is the first value, longitude is the second.
Résultat double[]

ParsePoint() public static méthode

Given a string containing dimension values encoded in it, separated by commas, return a String array of length dimension containing the values.
public static ParsePoint ( String _out, String externalVal, int dimension ) : String[]
_out String A preallocated array. Must be size dimension. If it is not it will be resized.
externalVal String The value to parse
dimension int The expected number of values for the point
Résultat String[]

ParsePointDouble() public static méthode

Given a string containing dimension values encoded in it, separated by commas, return a double array of length dimension containing the values.
public static ParsePointDouble ( double @out, String externalVal, int dimension ) : double[]
@out double
externalVal String The value to parse
dimension int The expected number of values for the point
Résultat double[]