public class MessageRetrievalParams
extends java.lang.Object
BaseMessage.getMessage(MessageRetrievalParams, BaseMessage.GetMessageHandler)
.Constructor and Description |
---|
MessageRetrievalParams(java.lang.String channelUrl,
BaseChannel.ChannelType channelType,
long messageId)
Create a
MessageRetrievalParams to use in BaseMessage.getMessage(MessageRetrievalParams, BaseMessage.GetMessageHandler) . |
Modifier and Type | Method and Description |
---|---|
MessageRetrievalParams |
clone()
Clones and returns a new instance of
MessageRetrievalParams . |
BaseChannel.ChannelType |
getChannelType()
Returns the
BaseChannel.ChannelType . |
java.lang.String |
getChannelUrl()
Returns the channel url.
|
long |
getMessageId()
Returns the message ID.
|
MessagePayloadFilter |
getMessagePayloadFilter()
Returns the
MessagePayloadFilter set in this param. |
void |
setIncludeMetaArray(boolean includeMetaArray)
Determines whether a meta array of the message is included in the results.
|
void |
setIncludeParentMessageText(boolean includeParentMessageText)
Deprecated.
As of 3.0.173, replaced by
setMessagePayloadFilter(MessagePayloadFilter) with MessagePayloadFilter.Builder.setIncludeParentMessageInfo(boolean) . |
void |
setIncludeThreadInfo(boolean includeThreadInfo)
Determines whether the thread information is included in the results set when the returned message is a parent message.
|
void |
setMessagePayloadFilter(MessagePayloadFilter messagePayloadFilter)
Sets the
MessagePayloadFilter to be used in retrieving message. |
boolean |
shouldIncludeMetaArray()
Returns whether the result message should include meta array.
|
boolean |
shouldIncludeParentMessageText()
Deprecated.
As of 3.0.173, replaced by
MessagePayloadFilter.shouldIncludeParentMessageInfo() from getMessagePayloadFilter() . |
boolean |
shouldIncludeThreadInfo()
Returns whether the thread information is included in the results set when the returned message is a parent message.
|
java.lang.String |
toString() |
public MessageRetrievalParams(java.lang.String channelUrl, BaseChannel.ChannelType channelType, long messageId)
MessageRetrievalParams
to use in BaseMessage.getMessage(MessageRetrievalParams, BaseMessage.GetMessageHandler)
.channelUrl
- Specifies the URL of the channel to retrieve the message.channelType
- Specifies the type of the channel.messageId
- Specifies the unique ID of the message to retrieve.public void setIncludeMetaArray(boolean includeMetaArray)
MessagePayloadFilter.setIncludeMetaArray(boolean)
.includeMetaArray
- If true
the result will be returned with meta arrays included.setMessagePayloadFilter(MessagePayloadFilter).
public void setIncludeThreadInfo(boolean includeThreadInfo)
MessagePayloadFilter.setIncludeThreadInfo(boolean)
.includeThreadInfo
- If true
the result will be returned with thread information included.setMessagePayloadFilter(MessagePayloadFilter).
@Deprecated public void setIncludeParentMessageText(boolean includeParentMessageText)
setMessagePayloadFilter(MessagePayloadFilter)
with MessagePayloadFilter.Builder.setIncludeParentMessageInfo(boolean)
.MessagePayloadFilter.Builder.setIncludeParentMessageInfo(boolean)
.includeParentMessageText
- If true
the result will be returned with messages with parent's message's text, if the message is a reply message.setMessagePayloadFilter(MessagePayloadFilter).
public void setMessagePayloadFilter(MessagePayloadFilter messagePayloadFilter)
MessagePayloadFilter
to be used in retrieving message.
This is more preferred way of setting other include flags.messagePayloadFilter
- MessagePayloadFilter
with preferred filters set.public java.lang.String getChannelUrl()
public BaseChannel.ChannelType getChannelType()
BaseChannel.ChannelType
.BaseChannel.ChannelType
.public long getMessageId()
public boolean shouldIncludeMetaArray()
getMessagePayloadFilter()
.public boolean shouldIncludeThreadInfo()
getMessagePayloadFilter()
.@Deprecated public boolean shouldIncludeParentMessageText()
MessagePayloadFilter.shouldIncludeParentMessageInfo()
from getMessagePayloadFilter()
.getMessagePayloadFilter()
.public MessagePayloadFilter getMessagePayloadFilter()
MessagePayloadFilter
set in this param.MessagePayloadFilter
.public MessageRetrievalParams clone()
MessageRetrievalParams
.clone
in class java.lang.Object
MessageRetrievalParams
.public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2021, Sendbird or its affiliates. All rights reserved.
Report a bug or request a feature
For further developer documentation, see Chat SDK Documentation. That documentation contains more detailed descriptions, conceptual overviews, definitions of terms, and code examples.