From: Sandro Santilli Date: Thu, 26 Aug 2004 16:55:09 +0000 (+0000) Subject: max_distance() raises an 'unimplemented yet' error. X-Git-Tag: pgis_0_9_1~38 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9cd8d8d04d91534eef1f645d5fa73cd030eec2a0;p=postgis max_distance() raises an 'unimplemented yet' error. git-svn-id: http://svn.osgeo.org/postgis/trunk@756 b70326c6-7e19-0410-871a-916f4a2858ee --- diff --git a/lwgeom/lwgeom_functions_basic.c b/lwgeom/lwgeom_functions_basic.c index 78e3dd385..a530af10a 100644 --- a/lwgeom/lwgeom_functions_basic.c +++ b/lwgeom/lwgeom_functions_basic.c @@ -1735,6 +1735,9 @@ Datum LWGEOM_maxdistance2d_linestring(PG_FUNCTION_ARGS) double maxdist = 0; int i; + elog(ERROR, "This function is unimplemented yet"); + PG_RETURN_NULL(); + geom1 = (LWGEOM *)PG_DETOAST_DATUM(PG_GETARG_DATUM(0)); line1 = lwline_deserialize(SERIALIZED_FORM(geom1)); if ( line1 == NULL ) PG_RETURN_NULL(); // not a linestring diff --git a/postgis_fn.c b/postgis_fn.c index acb7e204e..647798081 100644 --- a/postgis_fn.c +++ b/postgis_fn.c @@ -11,6 +11,9 @@ * ********************************************************************** * $Log$ + * Revision 1.40 2004/08/26 16:55:09 strk + * max_distance() raises an 'unimplemented yet' error. + * * Revision 1.39 2004/07/28 16:10:59 strk * Changed all version functions to return text. * Renamed postgis_scripts_version() to postgis_scripts_installed() @@ -467,7 +470,6 @@ Datum perimeter2d(PG_FUNCTION_ARGS) // // Our polygons have first and last point the same, // - int PIP( POINT3D *P, POINT3D *V, int n ) { int cn = 0; // the crossing number counter @@ -1125,7 +1127,8 @@ Datum combine_bbox(PG_FUNCTION_ARGS) } -//return 2 for 2d geometries or 3 for 3d geometries +//returns 0 for points, 1 for lines, 2 for polygons. +//returns max dimension for a collection. PG_FUNCTION_INFO_V1(dimension); Datum dimension(PG_FUNCTION_ARGS) { @@ -2442,6 +2445,9 @@ Datum max_distance(PG_FUNCTION_ARGS) double result,dist; + elog(ERROR, "This function is unimplemented yet"); + PG_RETURN_NULL(); + if (geom1->SRID != geom2->SRID) { elog(ERROR,"Operation on two GEOMETRIES with different SRIDs\n");