public DiskPathCollection Get(string potName) { PotDirectory potDirectory = PotDirectory.FromPotName(potName); if (!potDirectory.IsValid) { throw new Exception($"There is no pot with name '{potName}'."); } BlackListFile blackListFile = potDirectory.OpenBlackListFile("bl"); return(new DiskPathCollection(blackListFile.Items)); }
public void Delete(string potName, DiskPath path) { PotDirectory potDirectory = PotDirectory.FromPotName(potName); if (!potDirectory.IsValid) { throw new Exception($"There is no pot with name '{potName}'."); } BlackListFile blackListFile = potDirectory.OpenBlackListFile("bl"); blackListFile.Remove(path); blackListFile.Save(); }