System.ServiceModel.Dispatcher.DataContractMessagesFormatter.DataContractBodyWriter.OnWriteBodyContents C# (CSharp) Method

OnWriteBodyContents() protected method

protected OnWriteBodyContents ( XmlDictionaryWriter writer ) : void
writer System.Xml.XmlDictionaryWriter
return void
			protected override void OnWriteBodyContents (XmlDictionaryWriter writer)
			{
				int offset = HasReturnValue (desc) ? 1 : 0;
				if (desc.WrapperName != null)
					writer.WriteStartElement (desc.WrapperName, desc.WrapperNamespace);
				if (HasReturnValue (desc))
					WriteMessagePart (writer, desc, desc.ReturnValue, parts [0]);
				foreach (MessagePartDescription partDesc in desc.Parts)
					WriteMessagePart (writer, desc, partDesc, parts [partDesc.Index + offset]);
				if (desc.WrapperName != null)
					writer.WriteEndElement ();
			}
DataContractMessagesFormatter.DataContractBodyWriter