Esempio n. 1
0
        private void GenerateConfiguration(FieldInfo[] fragments, int?[] current)
        {
            ITarget target = Activator.CreateInstance(TargetType) as ITarget;

            for (int i = 0; i < fragments.Length; ++i)
            {
                fragments[i].SetValue(target, current[i] ?? 0);
            }

            string targetKey = target.GetType().FullName + "__" + target.GetTargetString();

            if (!_addedTargets.ContainsKey(targetKey))
            {
                _addedTargets.Add(targetKey, target);
                _targetObjects.Add(target);
            }
        }
Esempio n. 2
0
 public TrackedConfiguration FindConfiguration(ITarget target)
 {
     return(Configurations[target.GetTargetString()]);
 }