Multiple layers within a layer?

Topics: SharpMap v2.0
Sep 10, 2007 at 2:29 PM
We are just getting started with SharpMap casually right now, so I'm asking questions w/o doing lots of code exploration. However, our development will be intense starting in October/November, and we will be writing some custom data providers, layer implementations, and renderers. We have a situation where we want to display a map with irregularly shaped polygons. We have a function that creates a set of one or more "pretty" label locations for each polygon, and want to place labels at those locations. In our current COM implemtation our layers are something like in-memory shapefiles. And we have a layer that is actually a layer collection, with one member of the collection being the polygon with its own themes, and the other being a site layer, with the related label locations. Note that we can have multiple labels for a polygon, so we can't have a "LabelLocation" attribute on our polygon feature.

In SharpMap, out of the box, would we need to manage this scenario as two separate layers? And if so, can we write a "MultiLayer" layer class that implements the SharpMap layer interface, but when being rendered, would iterate through each member layer in its collection? Is something like this already done?