private bool GetAssemblies() { // clear assembly list m_AssemblyInfos = new List <IAssemblyInfo>(); List <Commands.DebuggingResolveAssembly> reply = Dbg.ResolveAllAssemblies(); foreach (Commands.DebuggingResolveAssembly resolvedAssm in reply) { AssemblyInfoFromResolveAssembly ai = new AssemblyInfoFromResolveAssembly(resolvedAssm); foreach (IAppDomainInfo adi in m_Domains) { if (Array.IndexOf <uint>(adi.AssemblyIndices, ai.Index) != -1) { ai.AddDomain(adi); } } m_AssemblyInfos.Add(ai); } // sanity check if (m_AssemblyInfos.Count == reply.Count) { // we have all the assemblies listed return(true); } // default to failure return(false); }
private async Task GetAssembliesAsync(CancellationToken cancellationToken) { List <Commands.DebuggingResolveAssembly> reply = await Dbg.ResolveAllAssembliesAsync(cancellationToken); if (reply != null) { foreach (Commands.DebuggingResolveAssembly resolvedAssm in reply) { AssemblyInfoFromResolveAssembly ai = new AssemblyInfoFromResolveAssembly(resolvedAssm); foreach (IAppDomainInfo adi in m_Domains) { if (Array.IndexOf <uint>(adi.AssemblyIndices, ai.Index) != -1) { ai.AddDomain(adi); } } m_AssemblyInfos.Add(ai); } } }