Class ListMessage
- java.lang.Object
-
- com.zendesk.sunshine_conversations_client.model.ListMessage
-
- All Implemented Interfaces:
Content
public class ListMessage extends java.lang.Object implements Content
List messages are a vertically scrollable set of items that may each contain text, an image, and message actions. Not all messaging channels fully support list messages. * Facebook Messenger and WeChat have native support. * For LINE and our Android, iOS and Web SDK, Sunshine Conversations converts list messages to carousel. * On WhatsApp, Telegram and Twitter, Sunshine Conversations converts list messages to multiple rich messages. * On all other platforms, Sunshine Conversations converts list messages to raw text.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringJSON_PROPERTY_ACTIONSstatic java.lang.StringJSON_PROPERTY_ITEMSstatic java.lang.StringJSON_PROPERTY_TYPE
-
Constructor Summary
Constructors Constructor Description ListMessage()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ListMessageactions(java.util.List<ActionSubset> actions)ListMessageaddActionsItem(ActionSubset actionsItem)ListMessageaddItemsItem(Item itemsItem)booleanequals(java.lang.Object o)java.util.List<ActionSubset>getActions()An array of objects representing the actions associated with the message.java.util.List<Item>getItems()An array of objects representing the items associated with the message.java.lang.StringgetType()The type of message.inthashCode()ListMessageitems(java.util.List<Item> items)voidsetActions(java.util.List<ActionSubset> actions)voidsetItems(java.util.List<Item> items)voidsetType(java.lang.String type)java.lang.StringtoString()ListMessagetype(java.lang.String type)
-
-
-
Field Detail
-
JSON_PROPERTY_TYPE
public static final java.lang.String JSON_PROPERTY_TYPE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_ITEMS
public static final java.lang.String JSON_PROPERTY_ITEMS
- See Also:
- Constant Field Values
-
JSON_PROPERTY_ACTIONS
public static final java.lang.String JSON_PROPERTY_ACTIONS
- See Also:
- Constant Field Values
-
-
Method Detail
-
type
public ListMessage type(java.lang.String type)
-
getType
public java.lang.String getType()
The type of message.
-
setType
public void setType(java.lang.String type)
-
items
public ListMessage items(java.util.List<Item> items)
-
addItemsItem
public ListMessage addItemsItem(Item itemsItem)
-
getItems
public java.util.List<Item> getItems()
An array of objects representing the items associated with the message. Only present in carousel and list type messages.- Returns:
- items
-
setItems
public void setItems(java.util.List<Item> items)
-
actions
public ListMessage actions(java.util.List<ActionSubset> actions)
-
addActionsItem
public ListMessage addActionsItem(ActionSubset actionsItem)
-
getActions
@Nullable public java.util.List<ActionSubset> getActions()
An array of objects representing the actions associated with the message. The array length is limited by the third party channel.- Returns:
- actions
-
setActions
public void setActions(java.util.List<ActionSubset> actions)
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-