Пример #1
0
 public void Remove(TargetElement details)
 {
     if (BaseIndexOf(details) >= 0)
     {
         BaseRemove(details.Name);
     }
 }
Пример #2
0
        private static TargetBase CreateFileTarget(TargetElement targetElement)
        {
            var target = new FileTarget
            {
                Path = targetElement.Path,
                DataType = GetTargetDataType(targetElement.Data),
                Name = targetElement.Name,
                Type = targetElement.Type,
                Parameters =
                    targetElement.Parameters.Cast<ParameterElement>()
                        .ToDictionary(param => param.Name, param => param.Value)
            };

            return target;
        }
Пример #3
0
        private static TargetBase CreateDatabaseTarget(TargetElement targetElement)
        {
            var target = new DatabaseTarget
            {
                CommandText = targetElement.CommandText,
                ConnectionString = ConfigurationManager.ConnectionStrings[targetElement.ConnectionStringName].ConnectionString,
                DataType = GetTargetDataType(targetElement.Data),
                Name = targetElement.Name,
                Type = targetElement.Type,
                Parameters =
                    targetElement.Parameters.Cast<ParameterElement>()
                        .ToDictionary(param => param.Name, param => param.Value)
            };

            return target;
        }
Пример #4
0
 public void Add(TargetElement details)
 {
     BaseAdd(details);
 }
Пример #5
0
 public int IndexOf(TargetElement details)
 {
     return(BaseIndexOf(details));
 }
Пример #6
0
 public void Remove(TargetElement details)
 {
     if (BaseIndexOf(details) >= 0)
         BaseRemove(details.Name);
 }
Пример #7
0
 public int IndexOf(TargetElement details)
 {
     return BaseIndexOf(details);
 }
Пример #8
0
 public void Add(TargetElement details)
 {
     BaseAdd(details);
 }