public ClrDump(DataTarget target, string dumpPath, MessageBus msgBus) { Id = n++; Target = target; DumpPath = dumpPath; MessageBus = msgBus; worker = new SingleThreadWorker(dumpPath); worker.Run(InitRuntime, OnError); ClrDumpInfo = ClrDumpInfo.Load(dumpPath); }
public void Run(Action action) { if (worker.Active) { worker.Run(action); } else { throw new InvalidOperationException($"{Id}: can't run action because worker is not active !"); } }