Package com.restfb.types
Class GraphResponse
- java.lang.Object
-
- com.restfb.types.GraphResponse
-
public class GraphResponse extends Object
Type that can be used as return value for publishing new objects to Facebook.Id, post_id and success field are accessible. Have a look at the fields and methods javadoc
-
-
Constructor Summary
Constructors Constructor Description GraphResponse()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
check()
String
getId()
String
getPostId()
String
getTimelineId()
returns the id that is used for the post or comment.boolean
isSuccess()
true
if publishing of the object was successful,false
otherwise.void
setId(String id)
void
setPostId(String postId)
void
setSuccess(boolean success)
true
if publishing of the object was successful,false
otherwise.
-
-
-
Constructor Detail
-
GraphResponse
public GraphResponse()
-
-
Method Detail
-
getTimelineId
public String getTimelineId()
returns the id that is used for the post or comment.Normally the
id
of the new object is returned, but after publishing a photo thepost id
is returned. So you get the id of the corresponding post without put the logic in your application.Attention: if you publish a photo without story you get the photo id here
- Returns:
- id of the new created post / comment
-
check
protected void check()
-
isSuccess
public boolean isSuccess()
true
if publishing of the object was successful,false
otherwise. if the success field is not provided by Facebook, we check if the id field is present
-
setSuccess
public void setSuccess(boolean success)
true
if publishing of the object was successful,false
otherwise. if the success field is not provided by Facebook, we check if the id field is present
-
-