public static LightDictionaryBase <string, object> GetOrAddAttachedValues(NotifyPropertyChangedBase model, bool addNew)
 {
     if (addNew && model.AttachedValues == null)
     {
         Interlocked.CompareExchange(ref model.AttachedValues, new AttachedValueDictionary(), null);
     }
     return(model.AttachedValues);
 }
Beispiel #2
0
        public static void ClearAttachedValues(NotifyPropertyChangedBase model)
        {
            var values = model.AttachedValues;

            if (values != null)
            {
                values.Clear();
            }
        }
 public static void ClearAttachedValues(NotifyPropertyChangedBase model)
 {
     model.AttachedValues?.Clear();
 }
Beispiel #4
0
            // *** Static Methods ***

            public static string GetPropertyName(Expression <Func <TestableNotifyPropertyChanged, object> > propertyExpression)
            {
                return(NotifyPropertyChangedBase.GetPropertyName(propertyExpression));
            }