RuntimeTracer
Namespace: Dotsider.Core.Analysis
Assembly: Dotsider.Core.dll
Launches a .NET target and collects its runtime diagnostics. Uses the bundled trace host to keep TraceEvent outside the Native AOT process. Exposes events, counters, output, and lifecycle state to dotsider callers.
public sealed class RuntimeTracer : IDisposableInheritance
Section titled “Inheritance”Object → RuntimeTracer
Implements
Section titled “Implements”Constructors
Section titled “Constructors”RuntimeTracer(string, IReadOnlyList<string>, Action)
Section titled “RuntimeTracer(string, IReadOnlyList<string>, Action)”Launches a .NET target and collects its runtime diagnostics. Uses the bundled trace host to keep TraceEvent outside the Native AOT process. Exposes events, counters, output, and lifecycle state to dotsider callers.
Parameters:
assemblyPath(String): The managed DLL or executable apphost to launch.arguments(IReadOnlyList<String>): The literal application arguments to pass to the launched process.invalidate(Action): The callback that requests a UI refresh.
public RuntimeTracer(string assemblyPath, IReadOnlyList<string> arguments, Action invalidate)Properties
Section titled “Properties”Elapsed
Section titled “Elapsed”The elapsed time since the trace was started.
Returns: TimeSpan
public TimeSpan Elapsed { get; }ErrorMessage
Section titled “ErrorMessage”The error message if the trace failed, or null.
Returns: String
public string? ErrorMessage { get; }ExitCode
Section titled “ExitCode”The exit code of the traced process, or null if not yet exited.
Returns: Nullable<Int32>
public int? ExitCode { get; }ProcessId
Section titled “ProcessId”The OS process ID of the traced process, or null if not started.
Returns: Nullable<Int32>
public int? ProcessId { get; }ProcessState
Section titled “ProcessState”The current state of the traced process.
Returns: TraceProcessState
public TraceProcessState ProcessState { get; }Methods
Section titled “Methods”Dispose()
Section titled “Dispose()”public void Dispose()GetEvents()
Section titled “GetEvents()”Returns a snapshot of all collected events (copied under lock).
Returns: IReadOnlyList<TraceEventEntry>
public IReadOnlyList<TraceEventEntry> GetEvents()GetLatestCounters()
Section titled “GetLatestCounters()”Returns the most recent counter snapshot, or null.
Returns: CounterSnapshot
public CounterSnapshot? GetLatestCounters()GetOutput()
Section titled “GetOutput()”Returns process output lines.
Returns: IReadOnlyList<OutputLine>
public IReadOnlyList<OutputLine> GetOutput()GetSummary()
Section titled “GetSummary()”Returns aggregated summary statistics.
Returns: TraceSummary
public TraceSummary GetSummary()Start()
Section titled “Start()”Launches the target process and starts collecting events.
public void Start()Stop()
Section titled “Stop()”Stops the traced process and event collection.
public void Stop()