Interface IChannelSummaryProvider

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      abstract boolean isSummaryType(MessageContent messageContent) Whether this template handles the given message content.
      abstract Spannable getSummarySpannable(Context context, T t) The content to display in the conversation list when the last message is of this type.
      abstract boolean showSummaryWithName() Whether to prepend the sender's name in the conversation summary.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

    • Method Detail

      • isSummaryType

         abstract boolean isSummaryType(MessageContent messageContent)

        Whether this template handles the given message content.

        Parameters:
        messageContent - the message content to check
        Returns:

        true if this template handles this message; the upper layer will then call getSummarySpannable to obtain the resource. false if this template does not handle this message.

      • getSummarySpannable

         abstract Spannable getSummarySpannable(Context context, T t)

        The content to display in the conversation list when the last message is of this type. For example, an image message should return the string "Image".

        Parameters:
        context - the context
        t - the message content
        Returns:

        the spannable string to display in the conversation list

      • showSummaryWithName

         abstract boolean showSummaryWithName()

        Whether to prepend the sender's name in the conversation summary. This setting only applies to group channels.

        Returns:

        whether to show the sender name