This demonstrates the ability to simulate having nodes be members of multiple "groups". Regular Groups only support a single Part.containingGroup for nodes. This sample does not make use of Groups at all, but simulates one possible "grouping" relationship using a custom Layout and a custom DraggingTool.

The CustomLayout assumes regular nodes already have real locations, and only assigns Part.location to "Super" nodes. It also sets the GraphObject.desiredSize on the "BODY" element of each "Super" node, based on the area occupied by all of its member nodes. The CustomDraggingTool overrides the DraggingTool.computeEffectiveCollection method to determine what nodes to drag around.

This sample does not support dynamic restructuring of the relationships in the graph.

Diagram Model saved in JSON format:
{ "nodeDataArray": [ { "key": -1, "text": "Operating", "category": "Super" }, { "key": -2, "text": "Drying", "category": "Super", "supers": [-1] }, { "key": -3, "text": "Non Drying", "category": "Super" }, { "key": 1, "loc": "100 100", "text": "Starting.End", "supers": [-2] }, { "key": 2, "loc": "250 100", "text": "Running", "supers": [-2] }, { "key": 3, "loc": "100 200", "text": "Starting.Init", "supers": [-1, -3] }, { "key": 4, "loc": "250 200", "text": "Washing", "supers": [-1, -3] }, { "key": 5, "loc": "100 300", "text": "Stopped", "supers": [-3] }, { "key": 6, "loc": "250 300", "text": "Stopping", "supers": [-3] } ], "linkDataArray": [ { "from": 1, "to": 2 }, { "from": 3, "to": 1 }, { "from": 4, "to": 2 }, { "from": -2, "to": 4 }, { "from": 5, "to": 3 }, { "from": 6, "to": 5 }, { "from": -1, "to": 5 } ] }