BatchFlow.Flow.Stop C# (CSharp) Method

Stop() public method

public Stop ( ) : void
return void
        public void Stop()
        {
            this.Status = RunStatus.Stopping;
            foreach (var node in Nodes)
            {
                node.Stop();

            }
            lock (_inProcessLock)
            {
                if (_inProcessCounter > 0)
                {
                    _ready.Release();// release for the possible runtocompletion
                    Thread.Sleep(10);
                    _ready.WaitOne();
                }
            }
            this.Status = RunStatus.Stopped;
        }