public void AddEntry(CASResult blte) { if (blte == null) { return; } // create the entry var entry = new EncodingCEKeyPageTable() { DecompressedSize = blte.DecompressedSize, CKey = blte.CEKey, }; entry.EKeys.Add(blte.EKey); if (CEKeys.ContainsKey(blte.CEKey)) // check if it exists { var existing = CEKeys[blte.CEKey]; if (EKeys.ContainsKey(existing.EKeys[0])) // remove old layout { EKeys.Remove(existing.EKeys[0]); } existing.EKeys[0] = blte.EKey; // update existing entry } else { CEKeys.Add(entry.CKey, entry); // new entry } AddLayoutEntry(blte); }
/// <summary> /// Determines where the specified EKeyEntry exists /// </summary> /// <param name="ekey"></param> /// <returns></returns> public bool ContainsEKey(MD5Hash ekey) => _EKeyEntries.ContainsKey(ekey);