Class PureBigraphMutable

java.lang.Object
org.bigraphs.framework.core.impl.pure.PureBigraph
org.bigraphs.framework.core.impl.pure.PureBigraphMutable
All Implemented Interfaces:
Bigraph<DynamicSignature>, EcoreBigraph<DynamicSignature>, EcoreBigraphExt, HasSignature<DynamicSignature>

public class PureBigraphMutable extends PureBigraph
Mutable extension of PureBigraph that supports live editing operations.

This class provides methods to modify the bigraph structure at runtime without requiring a complete rebuild. Changes are applied to both the EMF model and internal caches incrementally for optimal performance.

Key Features:

  • O(1) mutation operations (addNode, removeNode, etc.)
  • Automatic cache synchronization
  • Event notification for change listeners
  • Maintains consistency between EMF and entity collections

Usage Example:


 PureBigraphMutable bigraph = builder.createMutable();
 
 // Add a new node
 BigraphEntity.NodeEntity newNode = bigraph.addNode(parentNode, sensorControl, "sensor_1");
 
 // Remove a node
 bigraph.removeNode(nodeToRemove);
 
 // Connect to outer name
 bigraph.connectPortToOuterName(port, outerName);
 
Author:
Manuel Krombholz, AI Assistant (Mutable Extension)
See Also: