ObservesOnNotifyProperyChanged <TParameter1, TParameter2, TResult>(
            [NotNull] TParameter1 parameter1,
            [NotNull] TParameter2 parameter2,
            [NotNull] Expression <Func <TParameter1, TParameter2, TResult> > propertyExpression,
            bool isCached,
            LazyThreadSafetyMode safetyMode,
            bool isAutoActivate)
            where TResult : struct
            where TParameter1 : INotifyPropertyChanged
            where TParameter2 : INotifyPropertyChanged
        {
            var observer = new PropertyValueObserverOnNotifyProperyChanged <TParameter1, TParameter2, TResult>(
                parameter1,
                parameter2,
                propertyExpression,
                isCached,
                safetyMode, PropertyObserverFlag.None);

            if (isAutoActivate)
            {
                observer.Activate(true);
            }

            return(observer);
        }
示例#2
0
        public static IPropertyValueObserverOnNotifyProperyChanged <TResult> ObservesOnNotifyProperyChanged <TResult>(
            [NotNull] Expression <Func <TResult> > propertyExpression,
            bool isAutoActivate)
            where TResult : struct
        {
            var observer = new PropertyValueObserverOnNotifyProperyChanged <TResult>(propertyExpression, PropertyObserverFlag.None);

            if (isAutoActivate)
            {
                observer.Activate(true);
            }

            return(observer);
        }
        ObservesOnNotifyProperyChanged <TParameter1, TResult>(
            [NotNull] this TParameter1 parameter1,
            [NotNull] Expression <Func <TParameter1, TResult> > propertyExpression,
            bool isAutoActivate)
            where TResult : struct
            where TParameter1 : INotifyPropertyChanged
        {
            var observer =
                new PropertyValueObserverOnNotifyProperyChanged <TParameter1, TResult>(parameter1, propertyExpression, PropertyObserverFlag.None);

            if (isAutoActivate)
            {
                observer.Activate(true);
            }

            return(observer);
        }
示例#4
0
        public static IPropertyValueObserverOnNotifyProperyChanged <TResult> ObservesOnNotifyProperyChanged <TResult>(
            [NotNull] Expression <Func <TResult> > propertyExpression,
            bool isCached,
            LazyThreadSafetyMode safetyMode,
            TaskScheduler taskScheduler,
            bool isAutoActivate)
            where TResult : struct
        {
            var observer = new PropertyValueObserverOnNotifyProperyChanged <TResult>(
                propertyExpression,
                taskScheduler,
                isCached,
                safetyMode, PropertyObserverFlag.None);

            if (isAutoActivate)
            {
                observer.Activate(true);
            }

            return(observer);
        }