public virtual void FillAsClone(LGSPUniquenessEnsurer original, IDictionary <IGraphElement, IGraphElement> oldToNewMap) { nextNewId = original.nextNewId; heap.Clear(); // remove the -1 heap.Capacity = original.heap.Capacity; heap.AddRange(original.heap); }
public override void FillAsClone(LGSPUniquenessEnsurer original, IDictionary <IGraphElement, IGraphElement> oldToNewMap) { base.FillAsClone(original, oldToNewMap); LGSPUniquenessIndex originalIndex = (LGSPUniquenessIndex)original; if (originalIndex.index != null) { index = new List <IGraphElement>(originalIndex.index.Capacity); for (int i = 0; i < originalIndex.index.Count; ++i) { index.Add(oldToNewMap[originalIndex.index[i]]); } } }