public override void WriteObject(XmlWriter writer, object graph) { isValidResponse isValidResponseField = ((isValidResponse)(graph)); if (WriteParentElement(writer, true, true, graph)) { if (WriteChildElement(writer, "isValidResult", false, false, isValidResponseField.isValidResult)) { writer.WriteString(XmlConvert.ToString(isValidResponseField.isValidResult)); writer.WriteEndElement(); } writer.WriteEndElement(); } return; }
public override object ReadObject(XmlReader reader) { isValidResponse isValidResponseField = null; if (IsParentStartElement(reader, false, true)) { isValidResponseField = new isValidResponse(); reader.Read(); if (IsChildStartElement(reader, "isValidResult", false, false)) { reader.Read(); isValidResponseField.isValidResult = XmlConvert.ToBoolean(reader.ReadString()); reader.ReadEndElement(); } reader.ReadEndElement(); } return(isValidResponseField); }