Example #1
0
        public static Properties GetProperties(
            XmlElement element,
            string propElementName)
        {
            var properties = new Properties();
            foreach (var subElement in DOMElementEnumerator.For(element.ChildNodes)) {
                if (subElement.Name.Equals(propElementName)) {
                    var name = GetRequiredAttribute(subElement, "name");
                    var value = GetRequiredAttribute(subElement, "value");
                    properties.Put(name, value);
                }
            }

            return properties;
        }