[postgis-users] Reasonable Way to Convert MULTIPOINT to POINT?
dblasby at openplans.org
dblasby at openplans.org
Thu Feb 24 11:15:34 PST 2005
Martin Davis wrote:
>Generally, a clear pattern that has emerged from using the SFS API is
>that methods should be supported by ALL Geometry types if at all
>possible, using reasonable default return values if necessary.
>PostGIS/GEOS might want to consider providing similar methods.
Martin,
When I autogenerated the StaticGeometry class for Spatial DB in a Box,
these are the functions that it found that are not at the "top level":
static public int getNumGeometries(Geometry arg0)
{
GeometryCollection _this = (GeometryCollection) arg0;
return _this.getNumGeometries();
}
static public Geometry getGeometryN(Geometry arg0,int arg1)
{
GeometryCollection _this = (GeometryCollection) arg0;
return _this.getGeometryN(arg1);
}
static public double getX(Geometry arg0)
{
Point _this = (Point) arg0;
return _this.getX();
}
static public double getY(Geometry arg0)
{
Point _this = (Point) arg0;
return _this.getY();
}
static public boolean isClosed(Geometry arg0)
{
LineString _this = (LineString) arg0;
return _this.isClosed();
}
static public Geometry getPointN(Geometry arg0,int arg1)
{
LineString _this = (LineString) arg0;
return _this.getPointN(arg1);
}
static public Geometry getStartPoint(Geometry arg0)
{
LineString _this = (LineString) arg0;
return _this.getStartPoint();
}
static public Geometry getEndPoint(Geometry arg0)
{
LineString _this = (LineString) arg0;
return _this.getEndPoint();
}
static public boolean isRing(Geometry arg0)
{
LineString _this = (LineString) arg0;
return _this.isRing();
}
static public Geometry getExteriorRing(Geometry arg0)
{
Polygon _this = (Polygon) arg0;
return _this.getExteriorRing();
}
static public int getNumInteriorRing(Geometry arg0)
{
Polygon _this = (Polygon) arg0;
return _this.getNumInteriorRing();
}
static public Geometry getInteriorRingN(Geometry arg0,int arg1)
{
Polygon _this = (Polygon) arg0;
return _this.getInteriorRingN(arg1);
}
dave
----------------------------------------------------------
This mail sent through IMP: https://webmail.limegroup.com/
More information about the postgis-users
mailing list