public void RaiseEvent(IPipelineStage stage, IEvent @event) { if (IsEventRegistered(stage, @event)) { _currentstage = Pipeline.Configuration.Stages().FindStage(stage.Name); if (_currentstage.FindEvent(@event.GetType()) == null) { _currentstage.ForEvent(@event); } Pipeline.RaiseEvent(_currentstage.Name, @event); } }
IRegisterStage IRegisterStage.ForEvent <TEvent>() { _currentStage.ForEvent <TEvent>(); return(this); }