-
public abstract class BaseChannel
Objects representing a channel.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public enum
BaseChannel.ChannelType
Represents channel types.
OPEN
forOpenChannel
andGROUP
forGroupChannel
.public enum
BaseChannel.MessageTypeFilter
Represents messages type filter to be used when messages list are read.
USER
forUserMessage
,FILE
forFileMessage
andADMIN
forAdminMessage
.public interface
BaseChannel.GetMessagesHandler
GetMessages handler. This provides callback for all getting messages related methods.
public interface
BaseChannel.GetMessageChangeLogsHandler
GetMessageChangeLogsHandler handler. This provides callback for all getting message changelogs related methods.
public interface
BaseChannel.GetMessageChangeLogsByTokenHandler
GetMessageChangeLogsByToken handler. This provides callback for all getting message changelogs related methods.
public interface
BaseChannel.MetaCounterHandler
MetaCounter handler. This provides callback for all meta counter related methods.Refer to createMetaCounters.
public interface
BaseChannel.DeleteMetaCounterHandler
DeleteMetaCounter handler. This provides callback for deleteMetaCounter and deleteAllMetaCounters.
public interface
BaseChannel.MetaDataHandler
MetaData handler. This provides callback for all meta data related methods.Refer to createMetaData.
public interface
BaseChannel.DeleteMetaDataHandler
DeleteMetaData handler. This provides callback for deleteMetaData and deleteAllMetaData.
public interface
BaseChannel.SendUserMessageHandler
SendUserMessage handler. This provides callback for sendUserMessage and sendUserMessage.
public interface
BaseChannel.ResendUserMessageHandler
ResendUserMessage handler. This provides callback for resendUserMessage.
public interface
BaseChannel.TranslateUserMessageHandler
TranslateUserMessage handler. This provides callback for translateUserMessage.
public interface
BaseChannel.BaseSendFileMessageHandler
public interface
BaseChannel.SendFileMessageHandler
SendFileMessage handler.This provides callback for sendFileMessage and sendFileMessage.
public interface
BaseChannel.SendFileMessageWithProgressHandler
SendFileMessage handler.This provides callback for sendFileMessage.
public interface
BaseChannel.ResendFileMessageHandler
ResendFileMessage handler.This provides callback for resendFileMessage.
public interface
BaseChannel.ResendFileMessageWithProgressHandler
ResendFileMessage handler.This provides callback for resendFileMessage.
public interface
BaseChannel.SendFileMessagesHandler
SendFileMessages handler.This provides callback for sendFileMessages.
public interface
BaseChannel.SendFileMessagesWithProgressHandler
SendFileMessages handler.This provides callback for sendFileMessages.
public interface
BaseChannel.CopyUserMessageHandler
ForwardUserMessage handler.This provides callback for copyUserMessage.
public interface
BaseChannel.CopyFileMessageHandler
ForwardFileMessage handler.This provides callback for copyFileMessage.
public interface
BaseChannel.DeleteMessageHandler
DeleteMessage handler.This provides callback for deleteMessage.
public interface
BaseChannel.UpdateUserMessageHandler
A handler to receive a callback from updateUserMessage.
public interface
BaseChannel.UpdateFileMessageHandler
A handler to receive a callback from updateFileMessage.
public interface
BaseChannel.ReactionHandler
Reaction handler. This provides callback for reaction related methods.
public interface
BaseChannel.MessageMetaArrayHandler
MessageMetaArray handler.Refer to createMessageMetaArrayKeys, deleteMessageMetaArrayKeys, addMessageMetaArrayValues, removeMessageMetaArrayValues.
public interface
BaseChannel.GetMyMutedInfoHandler
GetMyMutedInfo handler. This handler provides callback for getMyMutedInfo.
public enum
BaseChannel.ReportCategory
Report category.
public interface
BaseChannel.ReportHandler
Report handler.This handler provides callback for report.
public interface
BaseChannel.ReportUserHandler
ReportUser handler.This handler provides callback for reportUser.
public interface
BaseChannel.ReportMessageHandler
ReportMessage handler.This handler provides callback for reportMessage.
-
Method Summary
Modifier and Type Method Description static BaseChannel
buildFromSerializedData(Array<byte> data)
Builds GroupChannel
orOpenChannel
instance from serialized datagenerated by serialize.Array<byte>
serialize()
Serializes the GroupChannel
orOpenChannel
instance.String
getData()
Returns channel data. String
getUrl()
Returns unique channel URL. long
getCreatedAt()
Returns channel creation time. String
getName()
Returns topic or name of the channel. String
getCoverUrl()
Returns cover image URL. boolean
isOpenChannel()
Checks whether the instance is OpenChannel type. boolean
isGroupChannel()
Checks whether the instance is GroupChannel type. boolean
isFrozen()
Checks if this channel is frozen. boolean
isEphemeral()
Checks if this channel is ephemeral. PreviousMessageListQuery
createPreviousMessageListQuery()
Creates previous message list query for this channel. MessageListQuery
createMessageListQuery()
Creates message list query for this channel. OperatorListQuery
createOperatorListQuery()
Creates a query instance to get the operator list from this channel. PollListQuery
createPollListQuery()
Creates a query instance to get the poll list from this channel. PollVoterListQuery
createPollVoterListQuery(long pollId, long pollOptionId)
Creates a query instance to get the voters of a poll option. void
getMessagesByMessageId(long messageId, MessageListParams params, BaseChannel.GetMessagesHandler handler)
Retrieves previous or next messages based on the message ID in a specific channel. void
getMessagesByTimestamp(long ts, MessageListParams params, BaseChannel.GetMessagesHandler handler)
Retrieves previous or next messages based on the timestamp in a specific channel. void
getNextMessagesByTimestamp(long ts, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given timestamp. void
getNextMessagesByTimestamp(long ts, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given timestamp. void
getNextMessagesByTimestamp(long ts, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given timestamp. void
getNextMessagesByTimestamp(long ts, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given timestamp. void
getPreviousMessagesByTimestamp(long ts, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given timestamp. void
getPreviousMessagesByTimestamp(long ts, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given timestamp. void
getPreviousMessagesByTimestamp(long ts, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given timestamp. void
getPreviousMessagesByTimestamp(long ts, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given timestamp. void
getPreviousAndNextMessagesByTimestamp(long ts, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, BaseChannel.GetMessagesHandler handler)
Requests the messages created before and after the given timestamp. void
getPreviousAndNextMessagesByTimestamp(long ts, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, BaseChannel.GetMessagesHandler handler)
Requests the messages created before and after the given timestamp. void
getPreviousAndNextMessagesByTimestamp(long ts, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, BaseChannel.GetMessagesHandler handler)
Requests the messages created before and after the given timestamp. void
getPreviousAndNextMessagesByTimestamp(long ts, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessagesHandler handler)
Requests the messages created before and after the given timestamp. void
getNextMessagesById(long msgId, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given ID. void
getNextMessagesById(long msgId, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given ID. void
getNextMessagesById(long msgId, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given ID. void
getNextMessagesById(long msgId, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given ID. void
getPreviousMessagesById(long msgId, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given ID. void
getPreviousMessagesById(long msgId, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given ID. void
getPreviousMessagesById(long msgId, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given ID. void
getPreviousMessagesById(long msgId, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given ID. void
getPreviousAndNextMessagesById(long msgId, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, BaseChannel.GetMessagesHandler handler)
Requests the messages created earlier or later than the given ID. void
getPreviousAndNextMessagesById(long msgId, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, BaseChannel.GetMessagesHandler handler)
Requests the messages created earlier or later than the given ID. void
getPreviousAndNextMessagesById(long msgId, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, BaseChannel.GetMessagesHandler handler)
Requests the messages created earlier or later than the given ID. void
getPreviousAndNextMessagesById(long msgId, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessagesHandler handler)
Requests the messages created earlier or later than the given ID. void
getMessageChangeLogsByToken(String token, BaseChannel.GetMessageChangeLogsByTokenHandler handler)
Requests the message changelogs from given token. void
getMessageChangeLogsByToken(String token, boolean includeMetaArray, BaseChannel.GetMessageChangeLogsByTokenHandler handler)
Requests the message changelogs from given token. void
getMessageChangeLogsByToken(String token, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessageChangeLogsHandler handler)
Requests message change logs after given timestamp. void
getMessageChangeLogsSinceToken(String token, MessageChangeLogsParams params, BaseChannel.GetMessageChangeLogsHandler handler)
Requests message change logs after given token. void
getMessageChangeLogsByTimestamp(long ts, BaseChannel.GetMessageChangeLogsHandler handler)
Requests message change logs after given timestamp. void
getMessageChangeLogsByTimestamp(long ts, boolean includeMetaArray, BaseChannel.GetMessageChangeLogsHandler handler)
Requests message change logs after given timestamp. void
getMessageChangeLogsByTimestamp(long ts, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessageChangeLogsHandler handler)
Requests message change logs after given timestamp. void
getMessageChangeLogsSinceTimestamp(long ts, MessageChangeLogsParams params, BaseChannel.GetMessageChangeLogsHandler handler)
Requests message change logs after given timestamp. FileMessage
sendFileMessage(String fileUrl, String name, String type, int size, String data, BaseChannel.SendFileMessageHandler handler)
Sends a file with given file information.File size value will only be used when sending a file message with a url. FileMessage
sendFileMessage(String fileUrl, String name, String type, int size, String data, String customType, BaseChannel.SendFileMessageHandler handler)
Sends a file with given file information.File size value will only be used when sending a file message with a url. FileMessage
sendFileMessage(File file, String name, String type, int size, String data, BaseChannel.SendFileMessageHandler handler)
Sends a file with given file information.File size value will only be used when sending a file message with a url. FileMessage
sendFileMessage(File file, String name, String type, int size, String data, String customType, BaseChannel.SendFileMessageHandler handler)
Sends a file with given file information.File size value will only be used when sending a file message with a url. FileMessage
sendFileMessage(File file, String name, String type, int size, String data, String customType, List<FileMessage.ThumbnailSize> thumbnailSizes, BaseChannel.SendFileMessageHandler handler)
Sends a file with given file information.File size value will only be used when sending a file message with a url. FileMessage
sendFileMessage(File file, String name, String type, int size, String data, BaseChannel.SendFileMessageWithProgressHandler handler)
Sends a file with given file information and gets callback for uploading progress.File size value will only be used when sending a file message with a url. FileMessage
sendFileMessage(File file, String name, String type, int size, String data, String customType, BaseChannel.SendFileMessageWithProgressHandler handler)
Sends a file with given file information and gets callback for uploading progress.File size value will only be used when sending a file message with a url. FileMessage
sendFileMessage(File file, String name, String type, int size, String data, String customType, List<FileMessage.ThumbnailSize> thumbnailSizes, BaseChannel.SendFileMessageWithProgressHandler handler)
Sends a file with given file information and gets callback for uploading progress.File size value will only be used when sending a file message with a url. FileMessage
sendFileMessage(FileMessageParams params, BaseChannel.SendFileMessageHandler handler)
Sends a file with given file information. FileMessage
sendFileMessage(FileMessageParams params, BaseChannel.SendFileMessageWithProgressHandler handler)
Sends a file with given file information and gets callback for uploading progress. List<FileMessage>
sendFileMessages(List<FileMessageParams> paramsList, BaseChannel.SendFileMessagesHandler handler)
Sends files with given files information.The maximum number of files is 20. List<FileMessage>
sendFileMessages(List<FileMessageParams> paramsList, BaseChannel.SendFileMessagesWithProgressHandler handler)
Sends files with given files information and gets callback for uploading progress.The maximum number of files is 20.This method handles FileMessageParams only which have set binary file not URL. UserMessage
sendUserMessage(String message, BaseChannel.SendUserMessageHandler handler)
Sends a user message. UserMessage
sendUserMessage(String message, String data, BaseChannel.SendUserMessageHandler handler)
Sends a user message. UserMessage
sendUserMessage(String message, String data, String customType, BaseChannel.SendUserMessageHandler handler)
Sends a user message. UserMessage
sendUserMessage(String message, String data, String customType, List<String> targetLanguages, BaseChannel.SendUserMessageHandler handler)
Sends a user message. UserMessage
sendUserMessage(UserMessageParams params, BaseChannel.SendUserMessageHandler handler)
Sends a user message. UserMessage
resendMessage(UserMessage userMessage, BaseChannel.ResendUserMessageHandler handler)
Resends a failed user message. FileMessage
resendMessage(FileMessage fileMessage, File file, BaseChannel.ResendFileMessageHandler handler)
Resends a file with given file information. FileMessage
resendMessage(FileMessage fileMessage, File file, BaseChannel.ResendFileMessageWithProgressHandler handler)
Resends a file with given file information and gets callback for uploading progress. void
resendFileMessage(FileMessage fileMessage, File file, BaseChannel.ResendFileMessageHandler handler)
Resends a file with given file information. void
resendFileMessage(FileMessage fileMessage, File file, BaseChannel.ResendFileMessageWithProgressHandler handler)
Resends a file with given file information and gets callback for uploading progress. void
resendUserMessage(UserMessage userMessage, BaseChannel.ResendUserMessageHandler handler)
Resends a failed user message. void
translateUserMessage(UserMessage userMessage, List<String> targetLanguages, BaseChannel.TranslateUserMessageHandler handler)
Translates a user message. FileMessage
copyFileMessage(BaseChannel targetChannel, FileMessage fileMessage, BaseChannel.CopyFileMessageHandler handler)
Copies a file message from this channel to the target channel. UserMessage
copyUserMessage(BaseChannel targetChannel, UserMessage userMessage, BaseChannel.CopyUserMessageHandler handler)
Copies a user message from this channel to the target channel. void
createMetaCounters(Map<String, Integer> metaCounterMap, BaseChannel.MetaCounterHandler handler)
Creates meta counters. void
updateMetaCounters(Map<String, Integer> metaCounterMap, BaseChannel.MetaCounterHandler handler)
Updates meta counters. void
increaseMetaCounters(Map<String, Integer> metaCounterMap, BaseChannel.MetaCounterHandler handler)
Increases meta counters. void
decreaseMetaCounters(Map<String, Integer> metaCounterMap, BaseChannel.MetaCounterHandler handler)
Decreases meta counters. void
getMetaCounters(Collection<String> keys, BaseChannel.MetaCounterHandler handler)
Gets meta counters. void
getAllMetaCounters(BaseChannel.MetaCounterHandler handler)
Get all meta counters. void
deleteMetaCounter(String key, BaseChannel.DeleteMetaCounterHandler handler)
Deletes a meta counter. void
deleteAllMetaCounters(BaseChannel.DeleteMetaCounterHandler handler)
Deletes all meta counters. void
createMetaData(Map<String, String> metaDataMap, BaseChannel.MetaDataHandler handler)
Creates meta data. void
updateMetaData(Map<String, String> metaDataMap, BaseChannel.MetaDataHandler handler)
Updates meta data. void
getMetaData(Collection<String> keys, BaseChannel.MetaDataHandler handler)
Gets meta data. void
getAllMetaData(BaseChannel.MetaDataHandler handler)
Gets all meta data. void
deleteMetaData(String key, BaseChannel.DeleteMetaDataHandler handler)
Deletes a meta data. void
deleteAllMetaData(BaseChannel.DeleteMetaDataHandler handler)
Deletes all meta data. void
deleteMessage(BaseMessage message, BaseChannel.DeleteMessageHandler handler)
Deletes a message. void
updateUserMessage(long messageId, String body, String data, String customType, BaseChannel.UpdateUserMessageHandler handler)
Updates a UserMessage
that was previously sent in the channel.void
updateUserMessage(long messageId, UserMessageParams params, BaseChannel.UpdateUserMessageHandler handler)
Updates a UserMessage
that was previously sent in the channel.void
updateFileMessage(long messageId, String data, String customType, BaseChannel.UpdateFileMessageHandler handler)
Updates a FileMessage
that was previously sent in the channel.Note that the file itself cannot be changed; only the fields stored within the message can be modified.void
updateFileMessage(long messageId, FileMessageParams params, BaseChannel.UpdateFileMessageHandler handler)
Updates a FileMessage
that was previously sent in the channel.Note that the file itself cannot be changed; only the fields stored within the message can be modified.boolean
cancelFileMessageUpload(String requestId)
Cancels an ongoing FileMessage
upload.void
addReaction(BaseMessage message, String key, BaseChannel.ReactionHandler handler)
Adds Reaction
.void
deleteReaction(BaseMessage message, String key, BaseChannel.ReactionHandler handler)
Deletes Reaction
.void
createMessageMetaArrayKeys(BaseMessage message, List<String> metaArrayKeys, BaseChannel.MessageMetaArrayHandler handler)
Creates message meta array keys. void
deleteMessageMetaArrayKeys(BaseMessage message, List<String> metaArrayKeys, BaseChannel.MessageMetaArrayHandler handler)
Deletes message meta array keys. void
addMessageMetaArrayValues(BaseMessage message, Map<String, List<String>> metaArrayMap, BaseChannel.MessageMetaArrayHandler handler)
Adds message meta array values. void
addMessageMetaArrayValues(BaseMessage message, List<MessageMetaArray> metaArrays, BaseChannel.MessageMetaArrayHandler handler)
Adds message meta array values. void
removeMessageMetaArrayValues(BaseMessage message, Map<String, List<String>> metaArrayMap, BaseChannel.MessageMetaArrayHandler handler)
Removes message meta array values. void
removeMessageMetaArrayValues(BaseMessage message, List<MessageMetaArray> metaArrays, BaseChannel.MessageMetaArrayHandler handler)
Removes message meta array values. void
getMyMutedInfo(BaseChannel.GetMyMutedInfoHandler handler)
Gets my muted information in this channel. void
report(BaseChannel.ReportCategory reportCategory, String reportDescription, BaseChannel.ReportHandler handler)
Reports this channel of inappropriate activities. void
reportUser(User offendingUser, BaseChannel.ReportCategory reportCategory, String reportDescription, BaseChannel.ReportUserHandler handler)
Reports a user of suspicious activities. void
reportMessage(BaseMessage message, BaseChannel.ReportCategory reportCategory, String reportDescription, BaseChannel.ReportMessageHandler handler)
Reports a malicious message. void
addOperators(Collection<String> userIds, AddOperatorsHandler handler)
Add operators to the channel. void
removeOperators(Collection<String> userIds, RemoveOperatorsHandler handler)
Remove operators from the channel. void
removeAllOperators(RemoveAllOperatorsHandler handler)
Remove all operators from the channel. final Map<String, String>
getCachedMetaData()
Returns all locally cached metadata as a map. String
toString()
boolean
equals(Object o)
int
hashCode()
-
-
Method Detail
-
buildFromSerializedData
static BaseChannel buildFromSerializedData(Array<byte> data)
Builds
GroupChannel
orOpenChannel
instance from serialized datagenerated by serialize.- Parameters:
data
- SerializedGroupChannel
orOpenChannel
data.
-
serialize
Array<byte> serialize()
Serializes the
GroupChannel
orOpenChannel
instance. This byte array can be storedin the database in your application. The instance can be restored by buildFromSerializedData.
-
getCreatedAt
long getCreatedAt()
Returns channel creation time.
-
getCoverUrl
String getCoverUrl()
Returns cover image URL.
-
isOpenChannel
boolean isOpenChannel()
Checks whether the instance is OpenChannel type.
-
isGroupChannel
boolean isGroupChannel()
Checks whether the instance is GroupChannel type.
-
isFrozen
boolean isFrozen()
Checks if this channel is frozen.
-
isEphemeral
boolean isEphemeral()
Checks if this channel is ephemeral.
-
createPreviousMessageListQuery
PreviousMessageListQuery createPreviousMessageListQuery()
Creates previous message list query for this channel.
-
createMessageListQuery
@Deprecated() MessageListQuery createMessageListQuery()
Creates message list query for this channel.
-
createOperatorListQuery
OperatorListQuery createOperatorListQuery()
Creates a query instance to get the operator list from this channel.
-
createPollListQuery
PollListQuery createPollListQuery()
Creates a query instance to get the poll list from this channel.
-
createPollVoterListQuery
PollVoterListQuery createPollVoterListQuery(long pollId, long pollOptionId)
Creates a query instance to get the voters of a poll option.
-
getMessagesByMessageId
void getMessagesByMessageId(long messageId, MessageListParams params, BaseChannel.GetMessagesHandler handler)
Retrieves previous or next messages based on the message ID in a specific channel.The result is passed to
handler
aslist
.- Parameters:
messageId
- Specifies the message ID to be the reference point for messages to retrieve.params
- Params for getting message list.handler
- Callback handler.
-
getMessagesByTimestamp
void getMessagesByTimestamp(long ts, MessageListParams params, BaseChannel.GetMessagesHandler handler)
Retrieves previous or next messages based on the timestamp in a specific channel.The result is passed to
handler
aslist
.- Parameters:
ts
- Specifies the timestamp to be the reference point for messages to retrieve, in Unix milliseconds format.params
- Params for getting message list.handler
- Callback handler.
-
getNextMessagesByTimestamp
@Deprecated() void getNextMessagesByTimestamp(long ts, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given timestamp.The result is passed to
handler
aslist
.- Parameters:
ts
- Starting message timestamp to load.isInclusive
- Whether messages sent exactly on the timestamp should be loaded.nextResultSize
- The number of messages sent after the timestamp that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.handler
- Callback handler.
-
getNextMessagesByTimestamp
@Deprecated() void getNextMessagesByTimestamp(long ts, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given timestamp.The result is passed to
handler
aslist
.- Parameters:
ts
- Starting message timestamp to load.isInclusive
- Whether messages sent exactly on the timestamp should be loaded.nextResultSize
- The number of messages sent after the timestamp that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.handler
- Callback handler.
-
getNextMessagesByTimestamp
@Deprecated() void getNextMessagesByTimestamp(long ts, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given timestamp.The result is passed to
handler
aslist
.- Parameters:
ts
- Starting message timestamp to load.isInclusive
- Whether messages sent exactly on the timestamp should be loaded.nextResultSize
- The number of messages sent after the timestamp that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.includeMetaArray
- Iftrue
the result will be returned with message meta array.handler
- Callback handler.
-
getNextMessagesByTimestamp
@Deprecated() void getNextMessagesByTimestamp(long ts, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given timestamp.The result is passed to
handler
aslist
.- Parameters:
ts
- Starting message timestamp to load.isInclusive
- Whether messages sent exactly on the timestamp should be loaded.nextResultSize
- The number of messages sent after the timestamp that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.includeMetaArray
- Iftrue
the result will be returned with message meta array.includeReactions
- Iftrue
the result will be returned with message reactions.handler
- Callback handler.
-
getPreviousMessagesByTimestamp
@Deprecated() void getPreviousMessagesByTimestamp(long ts, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given timestamp.The result is passed to
handler
aslist
.- Parameters:
ts
- Starting message timestamp to load.isInclusive
- Whether messages sent exactly on the timestamp should be loaded.prevResultSize
- The number of messages sent to prior to the timestamp that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.handler
- Callback handler.
-
getPreviousMessagesByTimestamp
@Deprecated() void getPreviousMessagesByTimestamp(long ts, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given timestamp.The result is passed to
handler
aslist
.- Parameters:
ts
- Starting message timestamp to load.isInclusive
- Whether messages sent exactly on the timestamp should be loaded.prevResultSize
- The number of messages sent to prior to the timestamp that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.handler
- Callback handler.
-
getPreviousMessagesByTimestamp
@Deprecated() void getPreviousMessagesByTimestamp(long ts, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given timestamp.The result is passed to
handler
aslist
.- Parameters:
ts
- Starting message timestamp to load.isInclusive
- Whether messages sent exactly on the timestamp should be loaded.prevResultSize
- The number of messages sent to prior to the timestamp that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.includeMetaArray
- Iftrue
the result will be returned with message meta array.handler
- Callback handler.
-
getPreviousMessagesByTimestamp
@Deprecated() void getPreviousMessagesByTimestamp(long ts, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given timestamp.The result is passed to
handler
aslist
.- Parameters:
ts
- Starting message timestamp to load.isInclusive
- Whether messages sent exactly on the timestamp should be loaded.prevResultSize
- The number of messages sent to prior to the timestamp that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.includeMetaArray
- Iftrue
the result will be returned with message meta array.includeReactions
- Iftrue
the result will be returned with message reactions.handler
- Callback handler.
-
getPreviousAndNextMessagesByTimestamp
@Deprecated() void getPreviousAndNextMessagesByTimestamp(long ts, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, BaseChannel.GetMessagesHandler handler)
Requests the messages created before and after the given timestamp.The result is passed to
handler
aslist
.- Parameters:
ts
- Starting message timestamp to load.prevResultSize
- The number of messages sent to prior to the timestamp that should be loaded.nextResultSize
- The number of messages sent after the timestamp that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.handler
- Callback handler.
-
getPreviousAndNextMessagesByTimestamp
@Deprecated() void getPreviousAndNextMessagesByTimestamp(long ts, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, BaseChannel.GetMessagesHandler handler)
Requests the messages created before and after the given timestamp.The result is passed to
handler
aslist
.- Parameters:
ts
- Starting message timestamp to load.prevResultSize
- The number of messages sent to prior to the timestamp that should be loaded.nextResultSize
- The number of messages sent after the timestamp that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.handler
- Callback handler.
-
getPreviousAndNextMessagesByTimestamp
@Deprecated() void getPreviousAndNextMessagesByTimestamp(long ts, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, BaseChannel.GetMessagesHandler handler)
Requests the messages created before and after the given timestamp.The result is passed to
handler
aslist
.- Parameters:
ts
- Starting message timestamp to load.prevResultSize
- The number of messages sent to prior to the timestamp that should be loaded.nextResultSize
- The number of messages sent after the timestamp that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.includeMetaArray
- Iftrue
the result will be returned with message meta array.handler
- Callback handler.
-
getPreviousAndNextMessagesByTimestamp
@Deprecated() void getPreviousAndNextMessagesByTimestamp(long ts, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessagesHandler handler)
Requests the messages created before and after the given timestamp.The result is passed to
handler
aslist
.- Parameters:
ts
- Starting message timestamp to load.prevResultSize
- The number of messages sent to prior to the timestamp that should be loaded.nextResultSize
- The number of messages sent after the timestamp that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.includeMetaArray
- Iftrue
the result will be returned with message meta array.includeReactions
- Iftrue
the result will be returned with message reactions.handler
- Callback handler.
-
getNextMessagesById
@Deprecated() void getNextMessagesById(long msgId, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given ID.The result is passed to
handler
aslist
.- Parameters:
msgId
- Starting message ID to load.isInclusive
- Whether the message exactly on the ID should be loaded.nextResultSize
- The number of messages sent after the ID that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.handler
- Callback handler.
-
getNextMessagesById
@Deprecated() void getNextMessagesById(long msgId, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given ID.The result is passed to
handler
aslist
.- Parameters:
msgId
- Starting message ID to load.isInclusive
- Whether the message exactly on the ID should be loaded.nextResultSize
- The number of messages sent after the ID that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.handler
- Callback handler.
-
getNextMessagesById
@Deprecated() void getNextMessagesById(long msgId, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given ID.The result is passed to
handler
aslist
.- Parameters:
msgId
- Starting message ID to load.isInclusive
- Whether the message exactly on the ID should be loaded.nextResultSize
- The number of messages sent after the ID that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.includeMetaArray
- Iftrue
the result will be returned with message meta array.handler
- Callback handler.
-
getNextMessagesById
@Deprecated() void getNextMessagesById(long msgId, boolean isInclusive, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessagesHandler handler)
Requests the next messages from given ID.The result is passed to
handler
aslist
.- Parameters:
msgId
- Starting message ID to load.isInclusive
- Whether the message exactly on the ID should be loaded.nextResultSize
- The number of messages sent after the ID that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.includeMetaArray
- Iftrue
the result will be returned with message meta array.includeReactions
- Iftrue
the result will be returned with message reactions.handler
- Callback handler.
-
getPreviousMessagesById
@Deprecated() void getPreviousMessagesById(long msgId, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given ID.The result is passed to
handler
aslist
.- Parameters:
msgId
- Starting message ID to load.isInclusive
- Whether the message exactly on the ID should be loaded.prevResultSize
- The number of messages sent to prior to the ID that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.handler
- Callback handler.
-
getPreviousMessagesById
@Deprecated() void getPreviousMessagesById(long msgId, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given ID.The result is passed to
handler
aslist
.- Parameters:
msgId
- Starting message ID to load.isInclusive
- Whether the message exactly on the ID should be loaded.prevResultSize
- The number of messages sent to prior to the ID that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.handler
- Callback handler.
-
getPreviousMessagesById
@Deprecated() void getPreviousMessagesById(long msgId, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given ID.The result is passed to
handler
aslist
.- Parameters:
msgId
- Starting message ID to load.isInclusive
- Whether the message exactly on the ID should be loaded.prevResultSize
- The number of messages sent to prior to the ID that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.includeMetaArray
- Iftrue
the result will be returned with message meta array.handler
- Callback handler.
-
getPreviousMessagesById
@Deprecated() void getPreviousMessagesById(long msgId, boolean isInclusive, int prevResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessagesHandler handler)
Requests the previous messages from given ID.The result is passed to
handler
aslist
.- Parameters:
msgId
- Starting message ID to load.isInclusive
- Whether the message exactly on the ID should be loaded.prevResultSize
- The number of messages sent to prior to the ID that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.includeMetaArray
- Iftrue
the result will be returned with message meta array.includeReactions
- Iftrue
the result will be returned with message reactions.handler
- Callback handler.
-
getPreviousAndNextMessagesById
@Deprecated() void getPreviousAndNextMessagesById(long msgId, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, BaseChannel.GetMessagesHandler handler)
Requests the messages created earlier or later than the given ID.The result is passed to
handler
aslist
.- Parameters:
msgId
- Starting message ID to load.prevResultSize
- The number of messages sent to prior to the ID that should be loaded.nextResultSize
- The number of messages sent after the ID that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.handler
- Callback handler.
-
getPreviousAndNextMessagesById
@Deprecated() void getPreviousAndNextMessagesById(long msgId, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, BaseChannel.GetMessagesHandler handler)
Requests the messages created earlier or later than the given ID.The result is passed to
handler
aslist
.- Parameters:
msgId
- Starting message ID to load.prevResultSize
- The number of messages sent to prior to the ID that should be loaded.nextResultSize
- The number of messages sent after the ID that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.handler
- Callback handler.
-
getPreviousAndNextMessagesById
@Deprecated() void getPreviousAndNextMessagesById(long msgId, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, BaseChannel.GetMessagesHandler handler)
Requests the messages created earlier or later than the given ID.The result is passed to
handler
aslist
.- Parameters:
msgId
- Starting message ID to load.prevResultSize
- The number of messages sent to prior to the ID that should be loaded.nextResultSize
- The number of messages sent after the ID that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.includeMetaArray
- Iftrue
the result will be returned with message meta array.handler
- Callback handler.
-
getPreviousAndNextMessagesById
@Deprecated() void getPreviousAndNextMessagesById(long msgId, int prevResultSize, int nextResultSize, boolean reverse, BaseChannel.MessageTypeFilter messageType, String customType, List<String> senderUserIds, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessagesHandler handler)
Requests the messages created earlier or later than the given ID.The result is passed to
handler
aslist
.- Parameters:
msgId
- Starting message ID to load.prevResultSize
- The number of messages sent to prior to the ID that should be loaded.nextResultSize
- The number of messages sent after the ID that should be loaded.reverse
- Iftrue
the result will be returned by creation time descending order.messageType
- Returns messages whose type matches BaseChannel.MessageTypeFilter.customType
- Returns messages that have a matching custom type.senderUserIds
- Returns messages whose sender user id matches sender user ids.includeMetaArray
- Iftrue
the result will be returned with message meta array.includeReactions
- Iftrue
the result will be returned with message reactions.handler
- Callback handler.
-
getMessageChangeLogsByToken
@Deprecated() void getMessageChangeLogsByToken(String token, BaseChannel.GetMessageChangeLogsByTokenHandler handler)
Requests the message changelogs from given token.The result is passed to
handler
.- Parameters:
token
- Token to get next message changelogs.handler
- Callback handler.
-
getMessageChangeLogsByToken
@Deprecated() void getMessageChangeLogsByToken(String token, boolean includeMetaArray, BaseChannel.GetMessageChangeLogsByTokenHandler handler)
Requests the message changelogs from given token.The result is passed to
handler
.- Parameters:
token
- Token to get next message changelogs.includeMetaArray
- Iftrue
the result will be returned with message meta array.handler
- Callback handler.
-
getMessageChangeLogsByToken
@Deprecated() void getMessageChangeLogsByToken(String token, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessageChangeLogsHandler handler)
Requests message change logs after given timestamp.The result is passed to
handler
.- Parameters:
token
- Token to get next message changelogs.includeMetaArray
- Iftrue
the result will be returned with message meta array.includeReactions
- Iftrue
the result will be returned with message reactions.handler
- Callback handler.
-
getMessageChangeLogsSinceToken
void getMessageChangeLogsSinceToken(String token, MessageChangeLogsParams params, BaseChannel.GetMessageChangeLogsHandler handler)
Requests message change logs after given token.The result is passed to
handler
.- Parameters:
token
- Specifies the token to be the reference point for the changelogs to retrieve.params
- Params for getting change logs.handler
- Callback handler.
-
getMessageChangeLogsByTimestamp
@Deprecated() void getMessageChangeLogsByTimestamp(long ts, BaseChannel.GetMessageChangeLogsHandler handler)
Requests message change logs after given timestamp.The result is passed to
handler
.- Parameters:
ts
- Specifies the timestamp to be the reference point for changelogs to retrieve, in Unix milliseconds format.handler
- Callback handler.
-
getMessageChangeLogsByTimestamp
@Deprecated() void getMessageChangeLogsByTimestamp(long ts, boolean includeMetaArray, BaseChannel.GetMessageChangeLogsHandler handler)
Requests message change logs after given timestamp.The result is passed to
handler
.- Parameters:
ts
- Timestamp to load change logs.includeMetaArray
- Iftrue
the result will be returned with message meta array.handler
- Callback handler.
-
getMessageChangeLogsByTimestamp
@Deprecated() void getMessageChangeLogsByTimestamp(long ts, boolean includeMetaArray, boolean includeReactions, BaseChannel.GetMessageChangeLogsHandler handler)
Requests message change logs after given timestamp.The result is passed to
handler
.- Parameters:
ts
- Timestamp to load change logs.includeMetaArray
- Iftrue
the result will be returned with message meta array.includeReactions
- Iftrue
the result will be returned with message reactions.handler
- Callback handler.
-
getMessageChangeLogsSinceTimestamp
void getMessageChangeLogsSinceTimestamp(long ts, MessageChangeLogsParams params, BaseChannel.GetMessageChangeLogsHandler handler)
Requests message change logs after given timestamp.The result is passed to
handler
.- Parameters:
ts
- Timestamp to load change logs.params
- Params for getting change logs.handler
- Callback handler.
-
sendFileMessage
FileMessage sendFileMessage(String fileUrl, String name, String type, int size, String data, BaseChannel.SendFileMessageHandler handler)
Sends a file with given file information.File size value will only be used when sending a file message with a url. When sending afile message with local file, Sendbird calculates the file size on your behalf and file sizevalue will be ignored.
- Parameters:
fileUrl
- URL of file to be sent.name
- File name.type
- File type.size
- File size.data
- Custom field.handler
- Callback handler.
-
sendFileMessage
FileMessage sendFileMessage(String fileUrl, String name, String type, int size, String data, String customType, BaseChannel.SendFileMessageHandler handler)
Sends a file with given file information.File size value will only be used when sending a file message with a url. When sending afile message with local file, Sendbird calculates the file size on your behalf and file sizevalue will be ignored.
- Parameters:
fileUrl
- URL of file to be sent.name
- File name.type
- File type.size
- File size.data
- Custom field.customType
- Custom type.handler
- Callback handler.
-
sendFileMessage
FileMessage sendFileMessage(File file, String name, String type, int size, String data, BaseChannel.SendFileMessageHandler handler)
Sends a file with given file information.File size value will only be used when sending a file message with a url. When sending afile message with local file, Sendbird calculates the file size on your behalf and file sizevalue will be ignored.
- Parameters:
file
- File to be sent.name
- File name.type
- File type.size
- File size.data
- Custom field.handler
- Callback handler.
-
sendFileMessage
@Deprecated() FileMessage sendFileMessage(File file, String name, String type, int size, String data, String customType, BaseChannel.SendFileMessageHandler handler)
Sends a file with given file information.File size value will only be used when sending a file message with a url. When sending afile message with local file, Sendbird calculates the file size on your behalf and file sizevalue will be ignored.
- Parameters:
file
- File to be sent.name
- File name.type
- File type.size
- File size.data
- Custom field.customType
- Custom type.handler
- Callback handler.
-
sendFileMessage
FileMessage sendFileMessage(File file, String name, String type, int size, String data, String customType, List<FileMessage.ThumbnailSize> thumbnailSizes, BaseChannel.SendFileMessageHandler handler)
Sends a file with given file information.File size value will only be used when sending a file message with a url. When sending afile message with local file, Sendbird calculates the file size on your behalf and file sizevalue will be ignored.
- Parameters:
file
- File to be sent.name
- File name.type
- File type.size
- File size.data
- Custom field.customType
- Custom type.thumbnailSizes
- Thumbnail sizes to be generated.handler
- Callback handler.
-
sendFileMessage
FileMessage sendFileMessage(File file, String name, String type, int size, String data, BaseChannel.SendFileMessageWithProgressHandler handler)
Sends a file with given file information and gets callback for uploading progress.File size value will only be used when sending a file message with a url. When sending afile message with local file, Sendbird calculates the file size on your behalf and file sizevalue will be ignored.
- Parameters:
file
- File to be sent.name
- File name.type
- File type.size
- File size.data
- Custom field.handler
- Callback handler.
-
sendFileMessage
@Deprecated() FileMessage sendFileMessage(File file, String name, String type, int size, String data, String customType, BaseChannel.SendFileMessageWithProgressHandler handler)
Sends a file with given file information and gets callback for uploading progress.File size value will only be used when sending a file message with a url. When sending afile message with local file, Sendbird calculates the file size on your behalf and file sizevalue will be ignored.
- Parameters:
file
- File to be sent.name
- File name.type
- File type.size
- File size.data
- Custom field.customType
- Custom type.handler
- Callback handler.
-
sendFileMessage
FileMessage sendFileMessage(File file, String name, String type, int size, String data, String customType, List<FileMessage.ThumbnailSize> thumbnailSizes, BaseChannel.SendFileMessageWithProgressHandler handler)
Sends a file with given file information and gets callback for uploading progress.File size value will only be used when sending a file message with a url. When sending afile message with local file, Sendbird calculates the file size on your behalf and file sizevalue will be ignored.
- Parameters:
file
- File to be sent.name
- File name.type
- File type.size
- File size.data
- Custom field.customType
- Custom type.thumbnailSizes
- Thumbnail sizes to be generated.handler
- Callback handler.
-
sendFileMessage
FileMessage sendFileMessage(FileMessageParams params, BaseChannel.SendFileMessageHandler handler)
Sends a file with given file information.
- Parameters:
params
- Params of file message.handler
- Callback handler.
-
sendFileMessage
FileMessage sendFileMessage(FileMessageParams params, BaseChannel.SendFileMessageWithProgressHandler handler)
Sends a file with given file information and gets callback for uploading progress.
- Parameters:
params
- Params of file message.handler
- Callback handler.
-
sendFileMessages
List<FileMessage> sendFileMessages(List<FileMessageParams> paramsList, BaseChannel.SendFileMessagesHandler handler)
Sends files with given files information.The maximum number of files is 20.
- Parameters:
paramsList
- List of params of file message.handler
- Callback handler.
-
sendFileMessages
List<FileMessage> sendFileMessages(List<FileMessageParams> paramsList, BaseChannel.SendFileMessagesWithProgressHandler handler)
Sends files with given files information and gets callback for uploading progress.The maximum number of files is 20.This method handles FileMessageParams only which have set binary file not URL.
- Parameters:
paramsList
- List of params of file message.handler
- Callback handler.
-
sendUserMessage
UserMessage sendUserMessage(String message, BaseChannel.SendUserMessageHandler handler)
Sends a user message.
- Parameters:
message
- String message.handler
- Callback handler.
-
sendUserMessage
@Deprecated() UserMessage sendUserMessage(String message, String data, BaseChannel.SendUserMessageHandler handler)
Sends a user message.
- Parameters:
message
- String message.data
- Custom field.handler
- Callback handler.
-
sendUserMessage
@Deprecated() UserMessage sendUserMessage(String message, String data, String customType, BaseChannel.SendUserMessageHandler handler)
Sends a user message.
- Parameters:
message
- String message.data
- Custom field.customType
- Custom type.handler
- Callback handler.
-
sendUserMessage
UserMessage sendUserMessage(String message, String data, String customType, List<String> targetLanguages, BaseChannel.SendUserMessageHandler handler)
Sends a user message.
- Parameters:
message
- String message.data
- Custom field.customType
- Custom type.targetLanguages
- Target language codes (for example "es" for spanish) the message will be translated to.handler
- Callback handler.
-
sendUserMessage
UserMessage sendUserMessage(UserMessageParams params, BaseChannel.SendUserMessageHandler handler)
Sends a user message.
- Parameters:
params
- Params of user message.handler
- Callback handler.
-
resendMessage
UserMessage resendMessage(UserMessage userMessage, BaseChannel.ResendUserMessageHandler handler)
Resends a failed user message.
- Parameters:
userMessage
- Failed user message.handler
- Callback handler.
-
resendMessage
FileMessage resendMessage(FileMessage fileMessage, File file, BaseChannel.ResendFileMessageHandler handler)
Resends a file with given file information.
- Parameters:
fileMessage
- Failed fileMessage.file
- File to resend.handler
- Callback handler.
-
resendMessage
FileMessage resendMessage(FileMessage fileMessage, File file, BaseChannel.ResendFileMessageWithProgressHandler handler)
Resends a file with given file information and gets callback for uploading progress.
- Parameters:
fileMessage
- Failed file message.file
- File to resend.handler
- Callback handler.
-
resendFileMessage
void resendFileMessage(FileMessage fileMessage, File file, BaseChannel.ResendFileMessageHandler handler)
Resends a file with given file information.
- Parameters:
fileMessage
- Failed fileMessage.file
- File to resend.handler
- Callback handler.
-
resendFileMessage
void resendFileMessage(FileMessage fileMessage, File file, BaseChannel.ResendFileMessageWithProgressHandler handler)
Resends a file with given file information and gets callback for uploading progress.
- Parameters:
fileMessage
- Failed file message.file
- File to resend.handler
- Callback handler.
-
resendUserMessage
void resendUserMessage(UserMessage userMessage, BaseChannel.ResendUserMessageHandler handler)
Resends a failed user message.
- Parameters:
userMessage
- Failed user message.handler
- Callback handler.
-
translateUserMessage
void translateUserMessage(UserMessage userMessage, List<String> targetLanguages, BaseChannel.TranslateUserMessageHandler handler)
Translates a user message.
- Parameters:
userMessage
- User message to translate.targetLanguages
- Target language codes (for example "es" for spanish) the message will be translated to.handler
- Callback handler.
-
copyFileMessage
FileMessage copyFileMessage(BaseChannel targetChannel, FileMessage fileMessage, BaseChannel.CopyFileMessageHandler handler)
Copies a file message from this channel to the target channel.
- Parameters:
targetChannel
- Target channel.fileMessage
- Message to be forwarded.handler
- Callback handler.
-
copyUserMessage
UserMessage copyUserMessage(BaseChannel targetChannel, UserMessage userMessage, BaseChannel.CopyUserMessageHandler handler)
Copies a user message from this channel to the target channel.
- Parameters:
targetChannel
- Target channel.userMessage
- Message to be forwarded.handler
- Callback handler.
-
createMetaCounters
void createMetaCounters(Map<String, Integer> metaCounterMap, BaseChannel.MetaCounterHandler handler)
Creates meta counters. This can be used to customize the channel.
- Parameters:
metaCounterMap
- Meta counter key-value map.handler
- Callback handler.
-
updateMetaCounters
void updateMetaCounters(Map<String, Integer> metaCounterMap, BaseChannel.MetaCounterHandler handler)
Updates meta counters.
- Parameters:
metaCounterMap
- Meta counter key-value map to update.handler
- Callback handler.
-
increaseMetaCounters
void increaseMetaCounters(Map<String, Integer> metaCounterMap, BaseChannel.MetaCounterHandler handler)
Increases meta counters. This increases atomically the keyed meta counter by the specified value.
- Parameters:
metaCounterMap
- Meta counter key-value map to increase by the specified value.handler
- Callback handler.
-
decreaseMetaCounters
void decreaseMetaCounters(Map<String, Integer> metaCounterMap, BaseChannel.MetaCounterHandler handler)
Decreases meta counters. This decreases atomically the keyed meta counter by the specified value.
- Parameters:
metaCounterMap
- Meta counter key-value map to decrease by the specified value.handler
- Callback handler.
-
getMetaCounters
void getMetaCounters(Collection<String> keys, BaseChannel.MetaCounterHandler handler)
Gets meta counters.
- Parameters:
keys
- Meta counters to get.handler
- Callback handler.
-
getAllMetaCounters
void getAllMetaCounters(BaseChannel.MetaCounterHandler handler)
Get all meta counters.
- Parameters:
handler
- Callback handler.
-
deleteMetaCounter
void deleteMetaCounter(String key, BaseChannel.DeleteMetaCounterHandler handler)
Deletes a meta counter.
- Parameters:
key
- Meta counter key to delete.handler
- Callback handler.
-
deleteAllMetaCounters
void deleteAllMetaCounters(BaseChannel.DeleteMetaCounterHandler handler)
Deletes all meta counters.
- Parameters:
handler
- Callback handler.
-
createMetaData
void createMetaData(Map<String, String> metaDataMap, BaseChannel.MetaDataHandler handler)
Creates meta data. This can be used to customize the channel.
- Parameters:
metaDataMap
- Meta data key-value map.handler
- Callback handler.
-
updateMetaData
void updateMetaData(Map<String, String> metaDataMap, BaseChannel.MetaDataHandler handler)
Updates meta data.
- Parameters:
metaDataMap
- Meta data key-value map to update.handler
- Callback handler.
-
getMetaData
void getMetaData(Collection<String> keys, BaseChannel.MetaDataHandler handler)
Gets meta data.
- Parameters:
keys
- Meta data to get.handler
- Callback handler.
-
getAllMetaData
void getAllMetaData(BaseChannel.MetaDataHandler handler)
Gets all meta data.
- Parameters:
handler
- Callback handler.
-
deleteMetaData
void deleteMetaData(String key, BaseChannel.DeleteMetaDataHandler handler)
Deletes a meta data.
- Parameters:
key
- Meta data key to delete.handler
- Callback handler.
-
deleteAllMetaData
void deleteAllMetaData(BaseChannel.DeleteMetaDataHandler handler)
Deletes all meta data.
- Parameters:
handler
- Callback handler.
-
deleteMessage
void deleteMessage(BaseMessage message, BaseChannel.DeleteMessageHandler handler)
Deletes a message.
- Parameters:
message
- Message to delete.handler
- Callback handler.
-
updateUserMessage
void updateUserMessage(long messageId, String body, String data, String customType, BaseChannel.UpdateUserMessageHandler handler)
Updates a
UserMessage
that was previously sent in the channel.- Parameters:
messageId
- The ID of the message.body
- The new message body.data
- The new Data associated with the message.customType
- The new Custom Type associated with the message.handler
- An UpdateUserMessageHandler to receive the callback from this method.
-
updateUserMessage
void updateUserMessage(long messageId, UserMessageParams params, BaseChannel.UpdateUserMessageHandler handler)
Updates a
UserMessage
that was previously sent in the channel.- Parameters:
messageId
- The ID of the message.params
- UserMessageParams.handler
- An UpdateFileMessageHandler to receive the callback from this method.
-
updateFileMessage
void updateFileMessage(long messageId, String data, String customType, BaseChannel.UpdateFileMessageHandler handler)
Updates a
FileMessage
that was previously sent in the channel.Note that the file itself cannot be changed; only the fields stored within the message can be modified.- Parameters:
messageId
- The ID of the message.data
- The new Data associated with the message.customType
- The new Custom Type associated with the message.handler
- An UpdateFileMessageHandler to receive the callback from this method.
-
updateFileMessage
void updateFileMessage(long messageId, FileMessageParams params, BaseChannel.UpdateFileMessageHandler handler)
Updates a
FileMessage
that was previously sent in the channel.Note that the file itself cannot be changed; only the fields stored within the message can be modified.- Parameters:
messageId
- The ID of the message.params
- FileMessageParams.handler
- An UpdateFileMessageHandler to receive the callback from this method.
-
cancelFileMessageUpload
boolean cancelFileMessageUpload(String requestId)
Cancels an ongoing
FileMessage
upload.- Parameters:
requestId
- TherequestId
of the message to cancel.
-
addReaction
void addReaction(BaseMessage message, String key, BaseChannel.ReactionHandler handler)
Adds
Reaction
.- Parameters:
message
- BaseMessage message.key
- String reaction key.handler
- Callback handler.
-
deleteReaction
void deleteReaction(BaseMessage message, String key, BaseChannel.ReactionHandler handler)
Deletes
Reaction
.- Parameters:
message
- BaseMessage message.key
- String reaction key.handler
- Callback handler.
-
createMessageMetaArrayKeys
void createMessageMetaArrayKeys(BaseMessage message, List<String> metaArrayKeys, BaseChannel.MessageMetaArrayHandler handler)
Creates message meta array keys.
- Parameters:
message
- Message.metaArrayKeys
- Meta array keys.handler
- Callback handler.
-
deleteMessageMetaArrayKeys
void deleteMessageMetaArrayKeys(BaseMessage message, List<String> metaArrayKeys, BaseChannel.MessageMetaArrayHandler handler)
Deletes message meta array keys.
- Parameters:
message
- Message.metaArrayKeys
- Meta array keys.handler
- Callback handler.
-
addMessageMetaArrayValues
@Deprecated() void addMessageMetaArrayValues(BaseMessage message, Map<String, List<String>> metaArrayMap, BaseChannel.MessageMetaArrayHandler handler)
Adds message meta array values.
- Parameters:
message
- Message.metaArrayMap
- Meta array key-value map.handler
- Callback handler.
-
addMessageMetaArrayValues
void addMessageMetaArrayValues(BaseMessage message, List<MessageMetaArray> metaArrays, BaseChannel.MessageMetaArrayHandler handler)
Adds message meta array values.
- Parameters:
message
- Message.metaArrays
- MessageMetaArray list.handler
- Callback handler.
-
removeMessageMetaArrayValues
@Deprecated() void removeMessageMetaArrayValues(BaseMessage message, Map<String, List<String>> metaArrayMap, BaseChannel.MessageMetaArrayHandler handler)
Removes message meta array values.
- Parameters:
message
- Message.metaArrayMap
- Meta array key-value map.handler
- Callback handler.
-
removeMessageMetaArrayValues
void removeMessageMetaArrayValues(BaseMessage message, List<MessageMetaArray> metaArrays, BaseChannel.MessageMetaArrayHandler handler)
Removes message meta array values.
- Parameters:
message
- Message.metaArrays
- MessageMetaArray list.handler
- Callback handler.
-
getMyMutedInfo
void getMyMutedInfo(BaseChannel.GetMyMutedInfoHandler handler)
Gets my muted information in this channel.
- Parameters:
handler
- Callback handler.
-
report
void report(BaseChannel.ReportCategory reportCategory, String reportDescription, BaseChannel.ReportHandler handler)
Reports this channel of inappropriate activities.
- Parameters:
reportCategory
- ReportCategory.reportDescription
- Report description.handler
- Callback handler.
-
reportUser
void reportUser(User offendingUser, BaseChannel.ReportCategory reportCategory, String reportDescription, BaseChannel.ReportUserHandler handler)
Reports a user of suspicious activities.
- Parameters:
offendingUser
- Offending user.reportCategory
- ReportCategory.reportDescription
- Report description.handler
- Callback handler.
-
reportMessage
void reportMessage(BaseMessage message, BaseChannel.ReportCategory reportCategory, String reportDescription, BaseChannel.ReportMessageHandler handler)
Reports a malicious message.
- Parameters:
message
- UserMessage or FileMessage.reportCategory
- ReportCategory.reportDescription
- Report description.handler
- Callback handler.
-
addOperators
void addOperators(Collection<String> userIds, AddOperatorsHandler handler)
Add operators to the channel. See https://docs.sendbird.com/platform/user_type#3_operator for the explanations on theoperators.
- Parameters:
userIds
- user ids to add as operators.handler
- handler to register
-
removeOperators
void removeOperators(Collection<String> userIds, RemoveOperatorsHandler handler)
Remove operators from the channel. See https://docs.sendbird.com/platform/user_type#3_operator for the explanations on theoperators.
- Parameters:
userIds
- user ids to remove from operators list.handler
- handler to register
-
removeAllOperators
void removeAllOperators(RemoveAllOperatorsHandler handler)
Remove all operators from the channel. See https://docs.sendbird.com/platform/user_type#3_operator for the explanations on theoperators.
- Parameters:
handler
- handler to register
-
getCachedMetaData
final Map<String, String> getCachedMetaData()
Returns all locally cached metadata as a map.Cached metadata is updated under following circumstances:
- getMetaData returned successfully
- getAllMetaData returned successfully
- deleteMetaData returned successfully
- deleteAllMetaData returned successfully
- updateMetaData returned successfully
- onMetaDataCreated is called
- onMetaDataUpdated is called
- onMetaDataDeleted is called
Please note that this method only caches values available in above methods: if getAllMetaData is never called on this instance, the map returnedby this method may not contain all metadata mappings.
-
hashCode
int hashCode()
-
-
-
-