Example #1
0
        public static void SetValue <TSource>(PropertyInfo propDestination, ConfigurationMap <TSource, TDestination> configMap)
        {
            if (configMap == null)
            {
                return;
            }

            var propSource = Source.GetProperty(configMap.SourceText);

            if (configMap.AppendValue == null)
            {
                SetValue(propSource, propDestination);
            }
            else
            {
                var propAppendValue = Source.GetProperty(configMap.AppendValueText);
                SetValue(propSource, configMap.SeparatorAppend, propDestination, propAppendValue);
            }
        }
Example #2
0
 public static void Set(ConfigurationMap <TSource, TDestination> configurationMap) =>
 ConfigurationMaps.Add(configurationMap);