Пример #1
0
        public GenericPropertyCollection Clone()
        {
            var properties = new GenericPropertyCollection();

            foreach (var item in this)
            {
                properties.Add(item.Clone());
            }

            return(properties);
        }
Пример #2
0
 public void CopyTo(GenericPropertyCollection properties)
 {
     foreach (var sourceProperty in this)
     {
         foreach (var targetProperty in properties)
         {
             if (sourceProperty.Equals(targetProperty))
             {
                 targetProperty.Value = sourceProperty.Value;
                 break;
             }
         }
     }
 }
Пример #3
0
        public GenericPropertyCollection GetPropertiesByScope(string scopeName)
        {
            var result = new GenericPropertyCollection();

            foreach (var item in this)
            {
                if (item.ScopeName == scopeName)
                {
                    result.Add(item);
                }
            }

            return(result);
        }