Пример #1
0
        public Photo[] GetPhotos()
        {
            PhotosResponse rsp = Session.Util.GetResponse <PhotosResponse> ("facebook.photos.get",
                                                                            FacebookParam.Create("aid", aid),
                                                                            FacebookParam.Create("session_key", Session.SessionKey),
                                                                            FacebookParam.Create("call_id", DateTime.Now.Ticks));

            foreach (Photo p in rsp.Photos)
            {
                p.Session = Session;
            }

            return(rsp.Photos);
        }
Пример #2
0
        public Photo GetPhoto()
        {
            PhotosResponse rsp = Session.Util.GetResponse <PhotosResponse> ("facebook.photos.get", FacebookParam.Create("pids", PId),
                                                                            FacebookParam.Create("session_key", Session.SessionKey),
                                                                            FacebookParam.Create("call_id", System.DateTime.Now.Ticks));

            if (rsp.Photos.Length < 1)
            {
                return(null);
            }

            rsp.Photos[0].Session = Session;
            return(rsp.Photos[0]);
        }