private static void LogProcessCount(ChromiumProcessManager p, int processCount) { // TODO Add logger Console.WriteLine(p.ToString() + processCount); /* * try * { * // p._logger?.LogInformation("Process Count: {ProcessCount}", processCount); * } * catch * { * // Prevent logging exception from causing havoc * }*/ }
public override Task KillAsync(ChromiumProcessManager p) => throw new ObjectDisposedException(p.ToString());
public override Task ExitAsync(ChromiumProcessManager p, TimeSpan timeout) => throw new ObjectDisposedException(p.ToString());
public void EnterFrom(ChromiumProcessManager p, State fromState) { if (!TryEnter(p, fromState)) { // Delegate Dispose to current state, because it has already changed since // transition to this state was initiated. p._currentState.Dispose(p); } else if (fromState != Exited) { Kill(p); p._exitCompletionSource.TrySetException(new ObjectDisposedException(p.ToString())); p._tempUserDataDir?.Dispose(); } }
public override void Dispose(ChromiumProcessManager p) { p._startCompletionSource.TrySetException(new ObjectDisposedException(p.ToString())); base.Dispose(p); }