Class AgentContentMessage

  • All Implemented Interfaces:
    java.lang.Cloneable, java.util.Map<java.lang.String,​java.lang.Object>

    public final class AgentContentMessage
    extends com.google.api.client.json.GenericJson
    The content of a message sent from the agent to a user.

    This is the Java data model class that specifies how to parse/serialize into the JSON that is transmitted over HTTP when working with the RCS Business Messaging API. For a detailed explanation see: https://developers.google.com/api-client-library/java/google-http-java-client/json

    Author:
    Google, Inc.
    • Nested Class Summary

      • Nested classes/interfaces inherited from class com.google.api.client.util.GenericData

        com.google.api.client.util.GenericData.Flags
      • Nested classes/interfaces inherited from class java.util.AbstractMap

        java.util.AbstractMap.SimpleEntry<K extends java.lang.Object,​V extends java.lang.Object>, java.util.AbstractMap.SimpleImmutableEntry<K extends java.lang.Object,​V extends java.lang.Object>
      • Nested classes/interfaces inherited from interface java.util.Map

        java.util.Map.Entry<K extends java.lang.Object,​V extends java.lang.Object>
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      AgentContentMessage clone()  
      ContentInfo getContentInfo()
      Information about a file, including the URL of the file and the URL of the file’s thumbnail.
      java.lang.String getFileName()
      The unique name of a file.
      RichCard getRichCard()
      A standalone rich card.
      java.util.List<Suggestion> getSuggestions()
      A list of suggested replies and suggested actions that appear as a list of suggestion chips following the associated agent message.
      java.lang.String getText()
      Text encoded in UTF-8.
      AgentContentMessage set​(java.lang.String fieldName, java.lang.Object value)  
      AgentContentMessage setContentInfo​(ContentInfo contentInfo)
      Information about a file, including the URL of the file and the URL of the file’s thumbnail.
      AgentContentMessage setFileName​(java.lang.String fileName)
      The unique name of a file.
      AgentContentMessage setRichCard​(RichCard richCard)
      A standalone rich card.
      AgentContentMessage setSuggestions​(java.util.List<Suggestion> suggestions)
      A list of suggested replies and suggested actions that appear as a list of suggestion chips following the associated agent message.
      AgentContentMessage setText​(java.lang.String text)
      Text encoded in UTF-8.
      • Methods inherited from class com.google.api.client.json.GenericJson

        getFactory, setFactory, toPrettyString, toString
      • Methods inherited from class com.google.api.client.util.GenericData

        entrySet, get, getClassInfo, getUnknownKeys, put, putAll, remove, setUnknownKeys
      • Methods inherited from class java.util.AbstractMap

        clear, containsKey, containsValue, equals, hashCode, isEmpty, keySet, size, values
      • Methods inherited from class java.lang.Object

        finalize, getClass, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.Map

        compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
    • Constructor Detail

      • AgentContentMessage

        public AgentContentMessage()
    • Method Detail

      • getContentInfo

        public ContentInfo getContentInfo()
        Information about a file, including the URL of the file and the URL of the file’s thumbnail. The RBM platform serves content from a cache, but an agent can force the RBM platform to fetch a new version of the content and refresh the cache.
        Returns:
        value or null for none
      • setContentInfo

        public AgentContentMessage setContentInfo​(ContentInfo contentInfo)
        Information about a file, including the URL of the file and the URL of the file’s thumbnail. The RBM platform serves content from a cache, but an agent can force the RBM platform to fetch a new version of the content and refresh the cache.
        Parameters:
        contentInfo - contentInfo or null for none
      • getFileName

        public java.lang.String getFileName()
        The unique name of a file. The RBM platform returns a file name when an agent uploads a file.
        Returns:
        value or null for none
      • setFileName

        public AgentContentMessage setFileName​(java.lang.String fileName)
        The unique name of a file. The RBM platform returns a file name when an agent uploads a file.
        Parameters:
        fileName - fileName or null for none
      • getRichCard

        public RichCard getRichCard()
        A standalone rich card.
        Returns:
        value or null for none
      • setRichCard

        public AgentContentMessage setRichCard​(RichCard richCard)
        A standalone rich card.
        Parameters:
        richCard - richCard or null for none
      • getSuggestions

        public java.util.List<Suggestion> getSuggestions()
        A list of suggested replies and suggested actions that appear as a list of suggestion chips following the associated agent message. Maximum 11 suggestions. The chips only display when the associated agent message is the most recent message within the conversation (including both agent and user messages). The user can tap a suggested reply to send the text reply back to the agent or tap a suggested action to initiate a native action on the device.
        Returns:
        value or null for none
      • setSuggestions

        public AgentContentMessage setSuggestions​(java.util.List<Suggestion> suggestions)
        A list of suggested replies and suggested actions that appear as a list of suggestion chips following the associated agent message. Maximum 11 suggestions. The chips only display when the associated agent message is the most recent message within the conversation (including both agent and user messages). The user can tap a suggested reply to send the text reply back to the agent or tap a suggested action to initiate a native action on the device.
        Parameters:
        suggestions - suggestions or null for none
      • getText

        public java.lang.String getText()
        Text encoded in UTF-8.
        Returns:
        value or null for none
      • setText

        public AgentContentMessage setText​(java.lang.String text)
        Text encoded in UTF-8.
        Parameters:
        text - text or null for none
      • set

        public AgentContentMessage set​(java.lang.String fieldName,
                                       java.lang.Object value)
        Overrides:
        set in class com.google.api.client.json.GenericJson
      • clone

        public AgentContentMessage clone()
        Overrides:
        clone in class com.google.api.client.json.GenericJson