Community Sub Channel
Community sub-channel.
community channel CommunityChannel under sub-channel, Used for organized by topic message. Inherits BaseChannel, reuse channel general Property and Operation.
Notification level settings
// Get sub-channel List
communityChannel.getSubChannels { list, error ->
list?.forEach { subChannel ->
println("${subChannel.subChannelId}: ${subChannel.name}")
}
}
// Clear sub-channel message
val params = ClearSubChannelMessagesParams(
timestamp = System.currentTimeMillis() - 86400000,
policy = MessageOperationPolicy.LOCAL_REMOTE
)
subChannel.clearMessages(params) { error ->
if (error == null) {
@param handler Operation result callback. Success when error null
}
}
subChannel.setNotificationLevel(NotificationLevel.MENTION) { error ->
subChannel.setNotificationLevel(NotificationLevel.MENTION) { error ->
if (error == null) {
}
}
}Properties
Inherited properties
Channel message push notification level.
Channel type
Message edit draft info.
Whether Contains machine people.
channel the last messages. Contains the last messages complete Info (Content, Sender, When time etc.).
channel within @ message (Including @Everyone) Unread count.
channel within Only @ me message Unread count.
channel Operation timestamp stamp (milli seconds).
Channel translation strategy.
Unread message count amount.
Functions
Based on ClearSubChannelMessagesParams.policy determine Clear range:
========================================
Whether sub-channel is public.
belonging to community channel ID (etc. same as channelId)
Whether sub-channel is public.
设置当前子频道的默认通知级别。
belonging to community channel ID (etc. same as channelId)
Inherited functions
*Note: 1 seconds minute Send message Not can exceed 5 items.
}
Usage Example:
Notification settings
) { message, error ->
Clear history messages.
Usage Example:
Usage Example:
Channel unique identifier
Channel message push notification level.
if (error == null) {
Channel type
Message edit draft info.
Usage Example:
Whether Contains machine people.
channel the last messages. Contains the last messages complete Info (Content, Sender, When time etc.).
channel within @ message (Including @Everyone) Unread count.
channel within Only @ me message Unread count.
From Local Data database re- New Get When before channel latest Info, Returns a New BaseChannel Object.
if (error == null && newChannel!= null) {
}
channel Operation timestamp stamp (milli seconds).
channel.removeTags(listOf("tag001", "tag002")) { error ->
// Draft cleared successfully
Channel translation strategy.
Unread message count amount.
// Cleared successfully
========================================
Delete message
}
从底层重新加载频道数据。
if (error == null) {
channel.sendMediaMessage(params, object: SendMediaMessageHandler {
channel.sendMessage(params, object: SendMessageHandler {
========================================
This Method Not Delete channel within message. If This channel has New message, This channel Convert re- New In List display,