Package com.restfb.types
Class GraphResponse
java.lang.Object
com.restfb.types.GraphResponse
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
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
check()
getId()
returns the id that is used for the post or comment.boolean
true
if publishing of the object was successful,false
otherwise.void
void
void
setSuccess
(boolean success) true
if publishing of the object was successful,false
otherwise.
-
Constructor Details
-
GraphResponse
public GraphResponse()
-
-
Method Details
-
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
-
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
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 -
getId
-
setId
-
getPostId
-
setPostId
-