Swig and contructor overloading...
steve.lime at DNR.STATE.MN.US
Thu Nov 3 12:40:08 EST 2005
Those methods exist and could be exposed, but I'd rather hide them within the
>>> Stephen Woodbridge <woodbri at swoodbridge.com> 11/02/05 9:58 PM >>>
Why not do something like PostGIS and create a functions like:
Steve Lime wrote:
> Hi all: Frank and I added some WKT support to MapServer 4.7/8 this
> past weekend. I updated the Swig interface file for the shapeObj
> (shape.i) and added a second parameter to the shapeObj constructor.
> It now looks like:
> shapeObj(int type=MS_SHAPE_NULL, char *wkt=NULL)
> Ideally you'd be able to create a shape with one or the other. Sean
> tells me this will be problematic for Java and C# based Swig modules
> because they don't handle default values. This change will break
> scripts then. Does anyone know if this is still true in the newest
> version of Swig? I know they did some work to standardize things
> across all languages recently. If this will be problem, then we have
> to address it. We could just tackle it with documentation since those
> bindings are not yet as popular. We could move creation from WKT into
> a seperate method. Or?
> Note that WKT reading/writing requires either OGR or GEOS support.
More information about the mapserver-dev