Hi,
I would like to plot about 10,000 points (lat/long) from a database on a WinformsMap. Additionally, once all 10k points are shown on the map, I would like to select a point on the map and show additional information retrieved from a database. I plan to use the cluster point style example to help display all of the points neatly at high out zoom levels.
Currently, I am taking each point from the database and creating a new PointShape object. Then the PointShape object is wrapped into a Feature object, then it's added to the InternalFeatures of a InMemoryFeatureLayer object. No column data yet. I am getting to somewhere near 8k points before an OutOfMemoryException is thrown (task manager at the time showed the program using a bit over 1gb).
After trying this, I noticed the MsSql2008FeatureLayer and will try this next and see how the memory efficiency is with that.
I figured I'd ask before implementing this time. Do you see anything wrong with this new SQL 2008 approach? Is there something I did wrong with the first approach and therefore I should see less memory usage if done correctly? Is there an alternative that I do not see?
Your help is much appreciated,
Derek
PS - A kind question/suggestion: I noticed the InternalFeatures is a GeoCollection which inherits from List<T>. My understanding is that List<T> requires contiguous memory allocations. When an OutOfMemoryException was thrown, I was still able to other applications without a problem while my application occupied the 1gb of memory. My understanding for this was that there was still memory available, but because it was not contiguous, I could not add more features to the map. Ideally, a program would be designed to use as little memory as possible, but still has ThinkGeo considered inheriting from a LinkedList<T> instead?