protected override object DoDeserializeValue(XmlReader reader, bool isSimpleValue)
        {
            reader.ReadStartElement(); // Read start of enclosing element
            ResourceProviderMetadata result = ResourceProviderMetadata.Deserialize(reader);

            reader.ReadEndElement(); // End of enclosing element
            return(result);
        }
        protected override object DoDeserializeValue(XmlReader reader, bool isSimpleValue)
        {
            ICollection <ResourceProviderMetadata> result = new List <ResourceProviderMetadata>();

            if (SoapHelper.ReadEmptyStartElement(reader)) // Read start of enclosing element
            {
                return(result);
            }
            while (reader.NodeType != XmlNodeType.EndElement)
            {
                result.Add(ResourceProviderMetadata.Deserialize(reader));
            }
            reader.ReadEndElement(); // End of enclosing element
            return(result);
        }