Renci.SshNet.Common.CountdownEvent.CountdownEvent C# (CSharp) Method

CountdownEvent() public method

Initializes a new instance of CountdownEvent class with the specified count.
If initialCount is zero, the event is created in a signaled state.
is less than zero.
public CountdownEvent ( int initialCount ) : System
initialCount int The number of signals initially required to set the .
return System
        public CountdownEvent(int initialCount)
        {
            if (initialCount < 0)
            {
                throw new ArgumentOutOfRangeException("initialCount");
            }

            _count = initialCount;

            var initialState = _count == 0;
            _event = new ManualResetEvent(initialState);
        }