public TemplatePropertyGroup(TemplatePropertyGroup source) : base(source) { _condition = source._condition; _properties = source._properties; _frameworkType = source._frameworkType; }
public TemplateItemGroup(TemplateItemGroup source) : base(source) { _items = source._items; _condition = source._condition; _frameworkType = source._frameworkType; }
/// <summary> /// This reads and sets its state or attributes stored in a <c>XML</c> format /// with the given reader. /// </summary> /// <param name="reader"> /// The reader with which the <c>XML</c> attributes of this object are accessed. /// </param> /// <exception cref="ArgumentNullException"> /// If the <paramref name="reader"/> is <see langword="null"/>. /// </exception> public override void ReadXml(XmlReader reader) { BuildExceptions.NotNull(reader, "reader"); Debug.Assert(reader.NodeType == XmlNodeType.Element); if (reader.NodeType != XmlNodeType.Element) { return; } if (!String.Equals(reader.Name, TagName, StringComparison.OrdinalIgnoreCase)) { return; } string tempText = reader.GetAttribute("FrameworkType"); if (!String.IsNullOrEmpty(tempText)) { _frameworkType = (TemplateFrameworkType)Enum.Parse( typeof(TemplateFrameworkType), tempText, true); } _condition = reader.GetAttribute("Condition"); if (reader.IsEmptyElement) { return; } if (_items == null || _items.Count != 0) { _items = new BuildList <TemplateItem>(); } while (reader.Read()) { if (reader.NodeType == XmlNodeType.Element) { if (String.Equals(reader.Name, TemplateItem.TagName, StringComparison.OrdinalIgnoreCase)) { TemplateItem item = new TemplateItem(); item.ReadXml(reader); if (!item.IsEmpty) { _items.Add(item); } } } else if (reader.NodeType == XmlNodeType.EndElement) { if (String.Equals(reader.Name, TagName, StringComparison.OrdinalIgnoreCase)) { break; } } } }
/// <summary> /// This reads and sets its state or attributes stored in a <c>XML</c> format /// with the given reader. /// </summary> /// <param name="reader"> /// The reader with which the <c>XML</c> attributes of this object are accessed. /// </param> /// <exception cref="ArgumentNullException"> /// If the <paramref name="reader"/> is <see langword="null"/>. /// </exception> public override void ReadXml(XmlReader reader) { BuildExceptions.NotNull(reader, "reader"); Debug.Assert(reader.NodeType == XmlNodeType.Element); if (reader.NodeType != XmlNodeType.Element) { return; } if (String.Equals(reader.Name, TagName, StringComparison.OrdinalIgnoreCase)) { string tempText = reader.GetAttribute("FrameworkType"); if (!String.IsNullOrEmpty(tempText)) { _frameworkType = (TemplateFrameworkType)Enum.Parse( typeof(TemplateFrameworkType), tempText, true); } } }
public TemplatePropertyGroup() { _condition = String.Empty; _properties = new BuildProperties(); _frameworkType = TemplateFrameworkType.None; }
public TemplateTargetFramework(TemplateTargetFramework source) : base(source) { _frameworkType = source._frameworkType; }
public TemplateTargetFramework() { _frameworkType = TemplateFrameworkType.None; }
public TemplateItemGroup() { _items = new BuildList <TemplateItem>(); _condition = String.Empty; _frameworkType = TemplateFrameworkType.None; }