private bool disposedValue = false; // To detect redundant calls protected virtual void Dispose(bool disposing) { if (!disposedValue) { if (disposing) { Project.Dispose(); tasker.Dispose(); relations.Dispose(); computers.Dispose(); computerIPs.Dispose(); files.Dispose(); Ips.Dispose(); computerDomains.Dispose(); lstLimits.Dispose(); domains.Dispose(); plugins.Dispose(); } Project = null; tasker = null; computerDomains = null; lstLimits = null; domains = null; relations = null; computers = null; files = null; Ips = null; plugins = null; disposedValue = true; } }
public Data() { Project = new Project(); files = new Ficheros(); Ips = new IPs(); domains = new Domains(); relations = new Relations(); computers = new Computers(); computerIPs = new ComputerIPs(); computerDomains = new ComputerDomains(); resolver = new Resolver(); #if PLUGINS plugins = new PluginList(); #endif lstLimits = new ThreadSafeList <Limits>(); }
public ComputerDomains GetComputerDomainsFromDomainsItem(DomainsItem dominio) { var lstComputers = new ComputerDomains(); var po = new ParallelOptions(); if (Program.cfgCurrent.ParallelDnsQueries != 0) { po.MaxDegreeOfParallelism = Program.cfgCurrent.ParallelDnsQueries; } Parallel.ForEach(Program.data.computerDomains.Items, S => { if ((S.Domain != null) && (S.Domain.Domain == dominio.Domain)) { lstComputers.Items.Add(S); } }); return(lstComputers); }