My application uses CustomDataSource to load entity data, and I have things working more or less the way I want them to. The data I'm showing is getting kind of busy, though, so I'm starting to look at clustering. The problem is, the individual DataSources that I use for my top-level entity types have natural subdivisions that would make whole-DataSource clusters combine items in a confusing way: think about a server-side data category of Fruit loaded into a single CustomDataSource, but I don't want to cluster Apples with Oranges.
Is there a simple way to do this within the framework, without adding an abstraction layer of my own on top? I notice that EntityCluster emits an event after deciding what to group together, but provides no way to decide which entities within a DataSource should go into each cluster.
I was thinking of making a DataSource type that is comprised of other DataSources (such that each child could have its own EntityCluster property), or maybe subclassing EntityCluster so that its grouping logic only puts Entities with a `parent` property in clusters with other Entities that share the same `parent`. Has anybody done something similar already? Is there another ready-to-go solution that I'm not seeing?