Im new to java trying to find a way to get info from facebook graph api,
for example:
I have the following graph page
https://graph.facebook.com/226949532466/albums
first im gonna get the page and read it
URL url = new URL("https://graph.facebook.com/226949532466/albums");
URLConnection conn = url.openConnection();
BufferedReader rd = new BufferedReader(new InputStreamReader(conn.getInputStream()));
but after that I would like to know is there an easy way to use (while) to get only the “name” of each group and collect them in an ArrayList
btw , im doing this on android if that makes a difference
Use
URL url = new URL("https://graph.facebook.com/226949532466/albums?fields=name");to get only the names.Suggestion: Please read the Facebook Graph API documentation properly. These are extremely basic questions that do not need to be asked here. Just spending thirty minutes going through the documentation will help you greatly.