setConversationToTop

public abstract void setConversationToTop(ConversationType conversationType, String targetId, String channelId, boolean isTop, IRongCoreCallback.ResultCallback<Boolean> callback)

Sets the pinned status of a conversation.

If the conversation does not exist, the SDK will automatically create and pin it when this method is called.

Since

5.6.8

Parameters

conversationType

The type of conversation .

targetId

The ID of the conversation. Depending on the conversationType, this could be a user ID, discussion group ID, group ID, or chatroom ID.

channelId

The business identifier of the conversation to which the message belongs.

isTop

Whether to pin the conversation.

callback

Callback indicating whether the pinning operation was successful.


public abstract void setConversationToTop(ConversationType conversationType, String id, String channelId, boolean isTop, boolean needCreate, boolean needUpdateTime, IRongCoreCallback.ResultCallback<Boolean> callback)

Sets the pinned status of a conversation.

If the conversation does not exist, calling this method will automatically create and pin the conversation.

Since

Dedicated Cloud 5.6.2

Parameters

conversationType

The type of conversation .

id

The ID of the conversation. Depending on the conversationType, this could be a user ID, discussion group ID, group ID, or chatroom ID.

channelId

The business identifier of the conversation to which the message belongs.

isTop

Whether to pin the conversation.

needCreate

Whether to create the conversation if it does not exist.

needUpdateTime

Whether to update the conversation timestamp.

callback

Callback indicating whether the pinning operation was successful.


@Deprecated()
public abstract void setConversationToTop(ConversationType conversationType, String targetId, String channelId, boolean isTop, boolean needCreate, IRongCoreCallback.ResultCallback<Boolean> callback)

Deprecated

Sets the pinned status of a conversation.

If the conversation does not exist, calling this method will automatically create and pin the conversation.

Since

5.1.1

Parameters

conversationType

The type of conversation .

targetId

The ID of the conversation. Depending on the conversationType, this could be a user ID, discussion group ID, group ID, or chatroom ID.

channelId

The business identifier of the conversation to which the message belongs.

isTop

Whether to pin the conversation.

needCreate

Whether to create the conversation if it does not exist.

callback

Callback to indicate whether the pinning operation was successful.