Example #1
0
 private void RegisterPropertyAttributes(string propName)
 {
     // Properties that are added after view model instantiation must be manually set so that
     // their values will be included in the updates to the client.
     foreach (var metaProp in RuntimeProperties.Where(x => x.Name.StartsWith(propName + "__")))
         Set(metaProp.Value, metaProp.Name);
 }
Example #2
0
        private void RemoveExistingProperty(string propName)
        {
            RuntimeProperties.Where(x => x.Name == propName || x.Name.Contains(propName + "__"))
               .ToList()
               .ForEach(x => RuntimeProperties.Remove(x));

            _propertyValues.TryRemove(propName, out object value);
        }