Esempio n. 1
0
 private void UpdateNodesAndSlostWithResolveMissingSlotAfterAction(IStorage storage, List<IVisualNode> nodeList, List<uint> slotIdList)
 {
     DataHeader header = new DataHeader();
     storage.Seek(12, SeekOrigin.Current); //By-pass the reading of total number of slots stored
     foreach (uint slotId in slotIdList)
     {
         header.Deserialize(storage);
         if (this.graphController.ContainSlotKey(slotId))
         {
             ISlot slot = this.graphController.GetSlot(slotId);
             slot.Deserialize(storage);
         }
         else
         {
             ISlot slot = Slot.Create(this.graphController, storage);
             this.graphController.AddSlot(slot);
         }
     }
     storage.Seek(12, SeekOrigin.Current); //By-pass the reading of total number of nodes stored
     foreach (IVisualNode node in nodeList)
     {
         header.Deserialize(storage);
         node.Deserialize(storage);
     }
 }