[mapguide-commits] r7608 - trunk/MgDev/Desktop/MgDesktop/Services/Feature/Commands

svn_mapguide at osgeo.org svn_mapguide at osgeo.org
Tue Jun 11 07:14:14 PDT 2013


Author: jng
Date: 2013-06-11 07:14:13 -0700 (Tue, 11 Jun 2013)
New Revision: 7608

Modified:
   trunk/MgDev/Desktop/MgDesktop/Services/Feature/Commands/DescribeSchema.cpp
Log:
mg-desktop: Having multiple extended feature classes of the same name will trip up bulk identity property loading of a MgMapBase-derived class. Although technically this shouldn't happen (as extended class names should be unique and authoring tools should be guarding against this), this submission adds a safeguard against this by bailing out of the extension loop once identity properties have been found, preventing subsequent classes of the same name (that shouldn't happen) from triggering MgDuplicateObjectExceptions if found when the loop is continued.

Modified: trunk/MgDev/Desktop/MgDesktop/Services/Feature/Commands/DescribeSchema.cpp
===================================================================
--- trunk/MgDev/Desktop/MgDesktop/Services/Feature/Commands/DescribeSchema.cpp	2013-06-11 14:03:29 UTC (rev 7607)
+++ trunk/MgDev/Desktop/MgDesktop/Services/Feature/Commands/DescribeSchema.cpp	2013-06-11 14:14:13 UTC (rev 7608)
@@ -1445,6 +1445,10 @@
                     {
                         extensionFeatureClass = (STRING)extension->GetFeatureClass();
                         GetIdentityProperties(extensionFeatureClass, currClass.p, idProps.p);
+                        //Break because
+                        // a) We've found and processed our extended class
+                        // b) Guards against duplicate extended classes of the same name defined in the Feature Source. Authoring tools *should not* let this happen
+                        break;
                     }
                 }
             }



More information about the mapguide-commits mailing list