void IXmlSerializable.WriteXml(Xml.XmlWriter writer) { writer.WriteStartElement("data"); writer.WriteAttributeString("name", this.ResourceKey); writer.WriteAttributeString("xml:space", "preserve"); ((IXmlSerializable)this.Value).WriteXml(writer); writer.WriteEndElement(); }
public void WriteXml(Xml.XmlWriter writer) { foreach (TKey key in this.Keys) { writer.WriteStartElement("item"); writer.WriteAttributeString("key", key.ToString()); writer.WriteAttributeString("value", this[key].ToString()); writer.WriteEndElement(); } }