ICButton
ICButton
This class exposes the data related to interactive button in quick replies and generic templates.
setType
This method to set the interactive data type for the button data.
Syntax: void setType(ICInteractiveDataType type)
Parameters:
Parameter | Type | Description |
---|---|---|
type | ICInteractiveDataType | The interactive data type for the button data. |
getType
This method is used to return interactive data type for the button data.
Syntax: ICInteractiveDataType getType()
Return Value: interactive data type for the button data.
getIdentifier
This method is used to return identifier for the button data.
Syntax: String getIdentifier()
Return Value: Identifier for the button data.
getImageURL
This method is used to return image URL for the button data.
Syntax: URL getImageURL()
Return Value: image URL for the button data.
getTitle
This method is used to return title for the button data.
Syntax: String getTitle()
Return Value: title for the button data.
getPayload
This method is used to return extra payload for the button data.
Syntax: JSONObject getPayload()
Returns: payload for the button data.
getActionURL
This method is used to return action URL for the button data.
Syntax: URL getActionURL()
Return Value: action URL for the button data.
fromJSON
Instantiates a new ICButton instance from the supplied JSONObject.
Syntax: public static ICButton fromJSON(JSONObject jsonObject)
Parameters:
Parameter | Type | Description |
---|---|---|
jsonObject | JSONObject | A valid JSONObject instance containing ICButton data. |
toJSON
This method returns a new JSONObject instance containing form ICButton data.
Syntax: public JSONObject toJSON() throws JSONException
Returns: A JSONObject representation of the ICButton data.
Throws: org.json.JSONException
Updated about 1 year ago