/// <summary> /// Creates empty structure which contains no data in containers. /// </summary> /// <param name="factories">The factories.</param> /// <returns> /// New empty structure which contains no data in containers. /// </returns> public static TrackingSnapshotStructureProxy CreateEmpty(ModularMemoryModelFactories factories) { TrackingSnapshotStructureProxy proxy = new TrackingSnapshotStructureProxy(factories); proxy.snapshotStructure = TrackingSnapshotStructureContainer.CreateEmpty(factories); proxy.readonlyInstance = proxy.snapshotStructure; proxy.isReadonly = false; return(proxy); }
/// <summary> /// Creates the structure with memory stack with global level only. /// </summary> /// <param name="factories">The factories.</param> /// <returns> /// New structure with memory stack with global level only. /// </returns> public static TrackingSnapshotStructureProxy CreateGlobal(ModularMemoryModelFactories factories) { TrackingSnapshotStructureProxy proxy = new TrackingSnapshotStructureProxy(factories); proxy.snapshotStructure = TrackingSnapshotStructureContainer.CreateEmpty(factories); proxy.isReadonly = false; proxy.snapshotStructure.AddStackLevel(Snapshot.GLOBAL_CALL_LEVEL); proxy.snapshotStructure.SetLocalStackLevelNumber(Snapshot.GLOBAL_CALL_LEVEL); proxy.readonlyInstance = proxy.snapshotStructure; return(proxy); }