protected override string Serialize(ContentItem entity) { using (var sw = new System.IO.StringWriter()) using (var xw = new XmlTextWriter(sw)) { #if DEBUG xw.Formatting = Formatting.Indented; #endif writer.WriteSingleItem(entity, Serialization.ExportOptions.ExcludeAttachments | Serialization.ExportOptions.ExcludeChildren, xw); return(sw.ToString()); } }