8000 Added Album.getPicture() method by wltjr · Pull Request #107 · roundrop/facebook4j · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Added Album.getPicture() method #107

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 30, 2017
Merged

Added Album.getPicture() method #107

merged 2 commits into from
Mar 30, 2017

Conversation

wltjr
Copy link
Contributor
@wltjr wltjr commented Jan 31, 2017

Added method to get an albums picture. This should be the cover photo, but seems you cannot get a URL for the image that way. This seems like the only way to get a link/url to the actual image for a given album. This is the album cover photo, or primary photo. Other methods did not seem to make this available.

Requires Reading fields "picture{url}"

ResponseList<Album> feed = facebook.getAlbums("Page", new Reading().fields(picture{url}));
feed.stream().foreach(album -> {
    URL picture = album.getPicture().getURL();
});

Sample Album JSON fields=id,name,picture{url}

{
  "data": [
  {
      "id": "11111111111111111",
      "name": "Album name",
      "picture": {
        "data": {
          "url": "https://scontent.xx.fbcdn.net/v/.....jpg"
        }
      }
    }
  ]

wltjr added 2 commits January 30, 2017 21:09
Added method to getPicture, returns Picture object. Cover photo does not
seem to have a way to get the album cover/primary picture. This method
allows for such.
Implemented getPicture() method, returns Picture object, if present
@roundrop roundrop merged commit f2d3b49 into roundrop:develop Mar 30, 2017
roundrop pushed a commit that referenced this pull request Mar 30, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0