예제 #1
0
        void IFlickrParsable.Load(XmlReader reader)
        {
            while (reader.NodeType != XmlNodeType.EndElement)
            {
                switch (reader.LocalName)
                {
                case "count":
                    Count = reader.ReadElementContentAsInt();
                    break;

                case "prevphoto":
                    PreviousPhoto = new ContextPhoto();
                    ((IFlickrParsable)PreviousPhoto).Load(reader);
                    if (PreviousPhoto.PhotoId == "0")
                    {
                        PreviousPhoto = null;
                    }
                    break;

                case "nextphoto":
                    NextPhoto = new ContextPhoto();
                    ((IFlickrParsable)NextPhoto).Load(reader);
                    if (NextPhoto.PhotoId == "0")
                    {
                        NextPhoto = null;
                    }
                    break;
                }
            }
        }
예제 #2
0
        void IFlickrParsable.Load(XmlReader reader)
        {
            while (reader.NodeType != XmlNodeType.EndElement)
            {
                switch (reader.LocalName)
                {
                    case "count":
                        Count = reader.ReadElementContentAsInt();
                        break;
                    case "prevphoto":
                        PreviousPhoto = new ContextPhoto();
                        ((IFlickrParsable)PreviousPhoto).Load(reader);
                        if (PreviousPhoto.PhotoId == "0") PreviousPhoto = null;
                        break;
                    case "nextphoto":
                        NextPhoto = new ContextPhoto();
                        ((IFlickrParsable)NextPhoto).Load(reader);
                        if (NextPhoto.PhotoId == "0") NextPhoto = null;
                        break;

                }
            }
        }