C# Class Spatial4n.Core.Util.GeohashUtils

Mostrar archivo Open project: synhershko/Spatial4n Class Usage Examples

Public Methods

Method Description
Decode ( String geohash, SpatialContext ctx ) : System.Point
DecodeBoundary ( String geohash, SpatialContext ctx ) : Rectangle
EncodeLatLon ( double latitude, double longitude ) : String

Encodes the given latitude and longitude into a geohash

EncodeLatLon ( double latitude, double longitude, int precision ) : String
GetSubGeohashes ( String baseGeohash ) : String[]
LookupDegreesSizeForHashLen ( int hashLen ) : double[]
LookupHashLenForWidthHeight ( double lonErr, double latErr ) : int

Return the shortest geohash length that will have a width & height >= specified arguments.

Private Methods

Method Description
GeohashUtils ( ) : System

Method Details

Decode() public static method

public static Decode ( String geohash, SpatialContext ctx ) : System.Point
geohash String
ctx Spatial4n.Core.Context.SpatialContext
return System.Point

DecodeBoundary() public static method

public static DecodeBoundary ( String geohash, SpatialContext ctx ) : Rectangle
geohash String
ctx Spatial4n.Core.Context.SpatialContext
return Rectangle

EncodeLatLon() public static method

Encodes the given latitude and longitude into a geohash
public static EncodeLatLon ( double latitude, double longitude ) : String
latitude double Latitude to encode
longitude double Longitude to encode
return String

EncodeLatLon() public static method

public static EncodeLatLon ( double latitude, double longitude, int precision ) : String
latitude double
longitude double
precision int
return String

GetSubGeohashes() public static method

public static GetSubGeohashes ( String baseGeohash ) : String[]
baseGeohash String
return String[]

LookupDegreesSizeForHashLen() public static method

public static LookupDegreesSizeForHashLen ( int hashLen ) : double[]
hashLen int
return double[]

LookupHashLenForWidthHeight() public static method

Return the shortest geohash length that will have a width & height >= specified arguments.
public static LookupHashLenForWidthHeight ( double lonErr, double latErr ) : int
lonErr double
latErr double
return int