/// <summary> /// Converts an object into its XML representation. /// </summary> /// <param name="writer">The <see cref="XmlWriter"/> stream to which the object is serialized.</param> public void WriteXml(XmlWriter writer) { writer.WriteAttributeString(nameof(Base), Base.AbsoluteUri); writer.WriteAttributeString(nameof(Popularity), Popularity.ToString(CultureInfo.InvariantCulture)); if (Profiles != null) { writer.WriteStartElement(nameof(ProfileRefList)); writer.WriteAttributeString("Key", nameof(Profiles)); Profiles.WriteXml(writer); writer.WriteEndElement(); } }
public string GetPopularity() { return(popularity.ToString()); }