2910{
2911
2915
2916 if (PG_ARGISNULL(0))
2917 {
2918 PG_RETURN_NULL();
2919 }
2920
2921 geom = PG_GETARG_GSERIALIZED_P(0);
2922
2923 if (!PG_ARGISNULL(1))
2924 {
2926 }
2927
2929 if (geohash)
2930 PG_RETURN_TEXT_P(geohash);
2931 PG_RETURN_NULL();
2932}
LWGEOM * lwgeom_from_gserialized(const GSERIALIZED *g)
Allocate a new LWGEOM from a GSERIALIZED.
lwvarlena_t * lwgeom_geohash(const LWGEOM *lwgeom, int precision)
Calculate the GeoHash (http://geohash.org) string for a geometry.