public void RaiseStartEvent() { StartHandler?.Invoke(this, new WorkItemEventArgs { Id = Id, WorkflowId = WorkflowId }); }
protected virtual void Start() { if (!_useStart) { _useStart = true; StartHandler?.Invoke(); OnEnableAfterStart(); } }
private void SetUpTree(string root) { if (!Directory.Exists(root)) { throw new DirectoryNotFoundException(root); } var rootDirInfo = new DirectoryInfo(root); StartHandler?.Invoke(this, EventArgs.Empty); _searchIsStopped = false; VisitFolder(rootDirInfo, null); _searchIsStopped = true; EndHandler?.Invoke(this, EventArgs.Empty); }