-
public class OpenGraphJSONUtilitycom.facebook.share.internal is solely for the use of other packages within the Facebook SDK for Android. Use of any of the classes in this package is unsupported, and they may be modified or removed without warning at any time.
Utility methods for JSON representation of Open Graph models.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public interfaceOpenGraphJSONUtility.PhotoJSONProcessor
-
Field Summary
Fields Modifier and Type Field Description public final static OpenGraphJSONUtilityINSTANCE
-
Method Summary
Modifier and Type Method Description final static JSONObjecttoJSONObject(ShareOpenGraphAction action, OpenGraphJSONUtility.PhotoJSONProcessor photoJSONProcessor)Converts an action to a JSONObject, return null if the action is null. final static ObjecttoJSONValue(Object value, OpenGraphJSONUtility.PhotoJSONProcessor photoJSONProcessor)Converts an value to a JSON value, return org.json.JSONObject.NULL if the value is null. -
-
Method Detail
-
toJSONObject
final static JSONObject toJSONObject(ShareOpenGraphAction action, OpenGraphJSONUtility.PhotoJSONProcessor photoJSONProcessor)
Converts an action to a JSONObject, return null if the action is null.
NOTE: All images are removed from the JSON representation and must be added to the builder separately.
- Parameters:
action- com.facebook.share.model.ShareOpenGraphAction to be converted.
-
toJSONValue
final static Object toJSONValue(Object value, OpenGraphJSONUtility.PhotoJSONProcessor photoJSONProcessor)
Converts an value to a JSON value, return org.json.JSONObject.NULL if the value is null. Return null if error happens.
NOTE: All images are removed from the JSON representation and must be added to the builder separately.
- Parameters:
value- the value to be converted.photoJSONProcessor- PhotoJSONProcessor object for processing photo objects.
-
-
-
-