[mapserver-commits] r9852 - trunk/mapserver

svn at osgeo.org svn at osgeo.org
Sun Feb 21 17:30:47 EST 2010


Author: hobu
Date: 2010-02-21 17:30:46 -0500 (Sun, 21 Feb 2010)
New Revision: 9852

Modified:
   trunk/mapserver/mapfile.c
   trunk/mapserver/maplayer.c
   trunk/mapserver/mapmssql2008.c
   trunk/mapserver/mapogr.cpp
   trunk/mapserver/maporaclespatial.c
   trunk/mapserver/mappluginlayer.c
   trunk/mapserver/mappostgis.c
   trunk/mapserver/mapproject.h
   trunk/mapserver/mapserver.h
   trunk/mapserver/mapshape.c
   trunk/mapserver/mapwfslayer.c
Log:
vtable description and start on RFC 37 #3333

Modified: trunk/mapserver/mapfile.c
===================================================================
--- trunk/mapserver/mapfile.c	2010-02-21 22:15:55 UTC (rev 9851)
+++ trunk/mapserver/mapfile.c	2010-02-21 22:30:46 UTC (rev 9852)
@@ -1084,6 +1084,7 @@
     case(MS_STRING):
     case(MS_AUTO):
       p->args[i] = strdup(msyytext);
+      p->automatic = MS_TRUE;
       i++;
       break;
     default:

Modified: trunk/mapserver/maplayer.c
===================================================================
--- trunk/mapserver/maplayer.c	2010-02-21 22:15:55 UTC (rev 9851)
+++ trunk/mapserver/maplayer.c	2010-02-21 22:30:46 UTC (rev 9852)
@@ -1033,6 +1033,13 @@
   return MS_FAILURE;
 }
 
+int LayerDefaultAutoProjection(layerObj *layer, projectionObj* projection)
+{
+
+    msSetError(MS_MISCERR, "This data driver does not implement AUTO projection support", "LayerDefaultAutoProjection()");
+    return MS_FAILURE;
+}
+
 /*
  * msConnectLayer
  *
@@ -1089,6 +1096,8 @@
   vtable->LayerCreateItems = LayerDefaultCreateItems;
     
   vtable->LayerGetNumFeatures = LayerDefaultGetNumFeatures;
+  
+  vtable->LayerGetAutoProjection = LayerDefaultAutoProjection;
 
   return MS_SUCCESS;
 }

Modified: trunk/mapserver/mapmssql2008.c
===================================================================
--- trunk/mapserver/mapmssql2008.c	2010-02-21 22:15:55 UTC (rev 9851)
+++ trunk/mapserver/mapmssql2008.c	2010-02-21 22:30:46 UTC (rev 9852)
@@ -1878,6 +1878,7 @@
     vtable->LayerSetTimeFilter = msLayerMakePlainTimeFilter;
     /* vtable->LayerCreateItems, use default */
     /* vtable->LayerGetNumFeatures, use default */
+    /* layer->vtable->LayerGetAutoProjection, use defaut*/
 
     return MS_SUCCESS;
 }

Modified: trunk/mapserver/mapogr.cpp
===================================================================
--- trunk/mapserver/mapogr.cpp	2010-02-21 22:15:55 UTC (rev 9851)
+++ trunk/mapserver/mapogr.cpp	2010-02-21 22:30:46 UTC (rev 9852)
@@ -3503,6 +3503,7 @@
     layer->vtable->LayerSetTimeFilter = msLayerMakeBackticsTimeFilter;
     /* layer->vtable->LayerCreateItems, use default */
     /* layer->vtable->LayerGetNumFeatures, use default */
+    /* layer->vtable->LayerGetAutoProjection, use defaut*/
 
     return MS_SUCCESS;
 }

Modified: trunk/mapserver/maporaclespatial.c
===================================================================
--- trunk/mapserver/maporaclespatial.c	2010-02-21 22:15:55 UTC (rev 9851)
+++ trunk/mapserver/maporaclespatial.c	2010-02-21 22:30:46 UTC (rev 9852)
@@ -3289,6 +3289,7 @@
     layer->vtable->LayerSetTimeFilter = msLayerMakePlainTimeFilter;
     /* layer->vtable->LayerCreateItems, use default */
     /* layer->vtable->LayerGetNumFeatures, use default */
+    /* layer->vtable->LayerGetAutoProjection, use defaut*/
 
     return MS_SUCCESS;
 }

Modified: trunk/mapserver/mappluginlayer.c
===================================================================
--- trunk/mapserver/mappluginlayer.c	2010-02-21 22:15:55 UTC (rev 9851)
+++ trunk/mapserver/mappluginlayer.c	2010-02-21 22:30:46 UTC (rev 9852)
@@ -175,6 +175,7 @@
     dest->LayerApplyFilterToLayer = src->LayerApplyFilterToLayer ? src->LayerApplyFilterToLayer : dest->LayerApplyFilterToLayer;
     dest->LayerCreateItems = src->LayerCreateItems ? src->LayerCreateItems : dest->LayerCreateItems;
     dest->LayerGetNumFeatures = src->LayerGetNumFeatures ? src->LayerGetNumFeatures : dest->LayerGetNumFeatures;
+    dest->LayerGetAutoProjection = src->LayerGetAutoProjection ? src->LayerGetAutoProjection: dest->LayerGetAutoProjection;
 }
 
 int

Modified: trunk/mapserver/mappostgis.c
===================================================================
--- trunk/mapserver/mappostgis.c	2010-02-21 22:15:55 UTC (rev 9851)
+++ trunk/mapserver/mappostgis.c	2010-02-21 22:30:46 UTC (rev 9852)
@@ -2586,6 +2586,8 @@
     layer->vtable->LayerSetTimeFilter = msPostGISLayerSetTimeFilter; 
     /* layer->vtable->LayerCreateItems, use default */
     /* layer->vtable->LayerGetNumFeatures, use default */
+    
+    /* layer->vtable->LayerGetAutoProjection, use defaut*/    
 
     return MS_SUCCESS;
 }

Modified: trunk/mapserver/mapproject.h
===================================================================
--- trunk/mapserver/mapproject.h	2010-02-21 22:15:55 UTC (rev 9851)
+++ trunk/mapserver/mapproject.h	2010-02-21 22:30:46 UTC (rev 9852)
@@ -47,6 +47,7 @@
   %immutable;
 #endif
   int numargs; /* actual number of projection args */
+  int automatic; /* projection object was to fetched from the layer */ 
 #ifdef SWIG
   %mutable;
 #endif

Modified: trunk/mapserver/mapserver.h
===================================================================
--- trunk/mapserver/mapserver.h	2010-02-21 22:15:55 UTC (rev 9851)
+++ trunk/mapserver/mapserver.h	2010-02-21 22:30:46 UTC (rev 9852)
@@ -1564,6 +1564,7 @@
 
     int (*LayerCreateItems)(layerObj *layer, int nt);
     int (*LayerGetNumFeatures)(layerObj *layer);
+    int (*LayerGetAutoProjection)(layerObj *layer, projectionObj *projection);
 };
 #endif /*SWIG*/
 

Modified: trunk/mapserver/mapshape.c
===================================================================
--- trunk/mapserver/mapshape.c	2010-02-21 22:15:55 UTC (rev 9851)
+++ trunk/mapserver/mapshape.c	2010-02-21 22:30:46 UTC (rev 9852)
@@ -2388,6 +2388,7 @@
   layer->vtable->LayerSetTimeFilter = msLayerMakeBackticsTimeFilter;
   /* layer->vtable->LayerCreateItems, use default */
   /* layer->vtable->LayerGetNumFeatures, use default */
+  /* layer->vtable->LayerGetAutoProjection, use defaut*/
 
   return MS_SUCCESS;
 }

Modified: trunk/mapserver/mapwfslayer.c
===================================================================
--- trunk/mapserver/mapwfslayer.c	2010-02-21 22:15:55 UTC (rev 9851)
+++ trunk/mapserver/mapwfslayer.c	2010-02-21 22:30:46 UTC (rev 9852)
@@ -1332,6 +1332,7 @@
     layer->vtable->LayerSetTimeFilter = msLayerMakePlainTimeFilter;
     /* layer->vtable->LayerCreateItems, use default */
     /* layer->vtable->LayerGetNumFeatures, use default */
+    /* layer->vtable->LayerGetAutoProjection, use defaut*/
 
     return MS_SUCCESS;
 }



More information about the mapserver-commits mailing list