//public static IDisposable SubscribeToRouter(this IObservable<Task> executionSequence, BindableBase model, string eventName, CallingCodeContext callingCodeContext) //{ // EventRouting.EventRouter.Instance.GetEventObject<TaskExecutionWindowEventArg>().RaiseEvent(model, eventName, callingCodeContext); // return executionSequence.Subscribe(); //} /// <summary> /// Register a Do action to the observer, Notify the value in this sequence to EventRouter /// </summary> /// <typeparam name="T">Sequence Value Type</typeparam> /// <param name="sequence">value sequence</param> /// <param name="eventRounter"> target </param> /// <param name="source">value source</param> /// <param name="registerName">log name</param> /// <returns>same value sequence inputed</returns> public static IObservable <T> DoNotifyEventRouter <T>(this IObservable <T> sequence, EventRouter eventRounter, object source = null, [CallerMemberName] string registerName = null) { return (sequence.Do( v => eventRounter.RaiseEvent(source, v, registerName) )); }