コード例 #1
0
ファイル: CatchSubject.cs プロジェクト: netmatze/SimpleRX
        private void ErrorExecute(Exception exception)
        {
            BaseSubject <T> secondsubject = (BaseSubject <T>)secondsource;

            this.secondsubject = secondsubject;
            var observer =
                new Observer <T>(
                    value => InnerExecute(value),
                    ex => NotifyErrorObservers(exception),
                    () => NotifyCompleteObservers());

            this.subscriped = secondsubject.Subscribe(observer);
        }
コード例 #2
0
        public FirstSubject(IObservable <T> source)
        {
            this.source = source;
            BaseSubject <T> subject = (BaseSubject <T>)source;

            this.subject = subject;
            var observer =
                new Observer <T>(
                    localvalue => InnerExecute(localvalue),
                    ex => NotifyErrorObservers(ex),
                    () => NotifyCompleteObservers());

            this.subscriped = subject.Subscribe(observer);
        }