internal static WindowsPhoneStoreServiceAppOfferNode ParseXml(XmlReader reader)
        {
            var node = new WindowsPhoneStoreServiceAppOfferNode();

            reader.ReadStartElement();

            while (reader.NodeType != XmlNodeType.EndElement)
            {
                switch (reader.LocalName)
                {
                case "offerId":
                    node.OfferId = reader.ReadElementContentAsUrn();
                    break;

                case "mediaInstanceId":
                    node.MediaInstanceId = reader.ReadElementContentAsUrn();
                    break;

                case "clientTypes":
                    node.ClientTypes = reader.ReadElementContentAsArray(x => x.ReadElementContentAsString());
                    break;

                case "paymentTypes":
                    node.PaymentTypes = reader.ReadElementContentAsArray(x => x.ReadElementContentAsString());
                    break;

                case "store":
                    node.Store = reader.ReadElementContentAsString();
                    break;

                case "price":
                    node.Price = reader.ReadElementContentAsDouble();
                    break;

                case "displayPrice":
                    node.DisplayPrice = reader.ReadElementContentAsString();
                    break;

                case "priceCurrencyCode":
                    node.PriceCurrencyCode = reader.ReadElementContentAsString();
                    break;

                case "licenseRight":
                    node.LicenseRight = reader.ReadElementContentAsString();
                    break;

                case "expiration":
                    node.Expiration = reader.ReadElementContentAsNullable <DateTime>();
                    break;

                default:
                    reader.Skip();
                    break;
                }
            }

            reader.ReadEndElement();

            return(node);
        }
        internal static WindowsPhoneStoreServiceAppOfferNode ParseXml(XmlReader reader)
        {
            var node = new WindowsPhoneStoreServiceAppOfferNode();

            reader.ReadStartElement();

            while (reader.NodeType != XmlNodeType.EndElement)
            {
                switch (reader.LocalName)
                {
                    case "offerId":
                        node.OfferId = reader.ReadElementContentAsUrn();
                        break;

                    case "mediaInstanceId":
                        node.MediaInstanceId = reader.ReadElementContentAsUrn();
                        break;

                    case "clientTypes":
                        node.ClientTypes = reader.ReadElementContentAsArray(x => x.ReadElementContentAsString());
                        break;

                    case "paymentTypes":
                        node.PaymentTypes = reader.ReadElementContentAsArray(x => x.ReadElementContentAsString());
                        break;

                    case "store":
                        node.Store = reader.ReadElementContentAsString();
                        break;

                    case "price":
                        node.Price = reader.ReadElementContentAsDouble();
                        break;

                    case "displayPrice":
                        node.DisplayPrice = reader.ReadElementContentAsString();
                        break;

                    case "priceCurrencyCode":
                        node.PriceCurrencyCode = reader.ReadElementContentAsString();
                        break;

                    case "licenseRight":
                        node.LicenseRight = reader.ReadElementContentAsString();
                        break;

                    case "expiration":
                        node.Expiration = reader.ReadElementContentAsNullable<DateTime>();
                        break;

                    default:
                        reader.Skip();
                        break;
                }
            }

            reader.ReadEndElement();

            return node;
        }