コード例 #1
0
                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
                     * }*/
                }
コード例 #2
0
 public override Task KillAsync(ChromiumProcessManager p) => throw new ObjectDisposedException(p.ToString());
コード例 #3
0
 public override Task ExitAsync(ChromiumProcessManager p, TimeSpan timeout) => throw new ObjectDisposedException(p.ToString());
コード例 #4
0
                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();
                    }
                }
コード例 #5
0
 public override void Dispose(ChromiumProcessManager p)
 {
     p._startCompletionSource.TrySetException(new ObjectDisposedException(p.ToString()));
     base.Dispose(p);
 }