System.Xml.Serialization.XmlSerializationWriterInterpreter.WritePrimitiveValueEncoded C# (CSharp) Method

WritePrimitiveValueEncoded() private method

private WritePrimitiveValueEncoded ( object memberValue, string name, string ns, XmlQualifiedName xsiType, XmlTypeMapping mappedType, TypeData typeData, bool wrapped, bool isNullable ) : void
memberValue object
name string
ns string
xsiType XmlQualifiedName
mappedType XmlTypeMapping
typeData TypeData
wrapped bool
isNullable bool
return void
		void WritePrimitiveValueEncoded (object memberValue, string name, string ns, XmlQualifiedName xsiType, XmlTypeMapping mappedType, TypeData typeData, bool wrapped, bool isNullable)
		{
			if (!wrapped) {
				WriteValue (GetStringValue (mappedType, typeData, memberValue));
			}
			else if (isNullable) {
				if (typeData.Type == typeof(XmlQualifiedName)) WriteNullableQualifiedNameEncoded (name, ns, (XmlQualifiedName)memberValue, xsiType);
				else WriteNullableStringEncoded (name, ns, GetStringValue (mappedType, typeData, memberValue), xsiType);
			}
			else {
				if (typeData.Type == typeof(XmlQualifiedName)) WriteElementQualifiedName (name, ns, (XmlQualifiedName)memberValue, xsiType);
				else WriteElementString (name, ns, GetStringValue (mappedType, typeData, memberValue), xsiType);
			}
		}