LeanCloud C# SDK
Public Member Functions | Properties | List of all members
LeanCloud.Realtime.LCIMConversation Class Reference

Conversation More...

Inheritance diagram for LeanCloud.Realtime.LCIMConversation:
Inheritance graph
[legend]

Public Member Functions

async Task< int > GetMembersCount ()
 The count of members of this conversation. More...
 
virtual async Task Read ()
 Mark the last message of this conversation as read. More...
 
async Task UpdateInfo (Dictionary< string, object > attributes)
 Update attributes of this conversation. More...
 
virtual async Task< LCIMPartiallySuccessResultAddMembers (IEnumerable< string > clientIds)
 Adds members to this conversation. More...
 
async Task< LCIMPartiallySuccessResultRemoveMembers (IEnumerable< string > removeIds)
 Removes members from this conversation. More...
 
async Task Join ()
 Joins this conversation. More...
 
async Task Quit ()
 Leaves this conversation. More...
 
async Task< LCIMMessageSend (LCIMMessage message, LCIMMessageSendOptions options=null)
 Sends a message in this conversation. More...
 
async Task Mute ()
 Turns off the offline notifications of this conversation. More...
 
async Task Unmute ()
 Turns on the offline notifications of this conversation. More...
 
async Task< LCIMPartiallySuccessResultMuteMembers (IEnumerable< string > clientIds)
 Mutes members of this conversation. More...
 
async Task< LCIMPartiallySuccessResultUnmuteMembers (IEnumerable< string > clientIds)
 Unmutes members of this conversation. More...
 
async Task< LCIMPartiallySuccessResultBlockMembers (IEnumerable< string > clientIds)
 Adds members to the blocklist of this conversation. More...
 
async Task< LCIMPartiallySuccessResultUnblockMembers (IEnumerable< string > clientIds)
 Removes members from the blocklist of this conversation. More...
 
async Task RecallMessage (LCIMMessage message)
 Recalls a sent message. More...
 
async Task UpdateMessage (LCIMMessage oldMessage, LCIMMessage newMessage)
 Updates a sent message. More...
 
async Task UpdateMemberRole (string memberId, string role)
 Updates the role of a member of this conversation. More...
 
async Task< ReadOnlyCollection< LCIMConversationMemberInfo > > GetAllMemberInfo ()
 Gets all member roles. More...
 
async Task< LCIMConversationMemberInfoGetMemberInfo (string memberId)
 Gets the role of a specific member. More...
 
async Task< LCIMPageResultQueryMutedMembers (int limit=10, string next=null)
 Queries muted members. More...
 
async Task< LCIMPageResultQueryBlockedMembers (int limit=10, string next=null)
 Queries blocked members. More...
 
async Task< ReadOnlyCollection< LCIMMessage > > QueryMessages (LCIMMessageQueryEndpoint start=null, LCIMMessageQueryEndpoint end=null, LCIMMessageQueryDirection direction=LCIMMessageQueryDirection.NewToOld, int limit=20, int messageType=0)
 Retrieves messages. More...
 
virtual async Task FetchReciptTimestamps ()
 Fetches receipt timestamp. More...
 
async Task< LCIMConversationFetch ()
 Fetch conversation from server. More...
 

Properties

string Id [get, set]
 The ID of this conversation More...
 
bool Unique [get, set]
 Indicates whether this conversation is normal and unique. The uniqueness is based on the members when creating. More...
 
string UniqueId [get, set]
 If this conversation is unique, then it will have a unique ID. More...
 
string Name [get, set]
 The name of this conversation. More...
 
string CreatorId [get, set]
 The creator of this conversation. More...
 
ReadOnlyCollection< string > MemberIds [get]
 The members of this conversation. More...
 
ReadOnlyCollection< string > MutedMemberIds [get]
 Muted members of this conversation. More...
 
int Unread [get, set]
 The count of the unread messages. More...
 
LCIMMessage LastMessage [get, set]
 The last message in this conversation. More...
 
DateTime CreatedAt [get, set]
 The created date of this conversation. More...
 
DateTime UpdatedAt [get, set]
 The last updated date of this conversation. More...
 
long LastDeliveredTimestamp [get, set]
 The last timestamp of the delivered message. More...
 
DateTime LastDeliveredAt [get]
 The last date of the delivered message. More...
 
long LastReadTimestamp [get, set]
 The last timestamp of the message which has been read by other clients. More...
 
DateTime LastReadAt [get]
 The last date of the message which has been read by other clients. More...
 
object this[string key] [get, set]
 Custom attributes. More...
 
bool IsMute [get]
 Indicates whether offline notifications about this conversation has been muted. More...
 
LCIMClient Client [get]
 

Detailed Description

Conversation

Member Function Documentation

virtual async Task<LCIMPartiallySuccessResult> LeanCloud.Realtime.LCIMConversation.AddMembers ( IEnumerable< string >  clientIds)
inlinevirtual

Adds members to this conversation.

Parameters
clientIdsMember list.
Returns

Reimplemented in LeanCloud.Realtime.LCIMChatRoom.

async Task<LCIMPartiallySuccessResult> LeanCloud.Realtime.LCIMConversation.BlockMembers ( IEnumerable< string >  clientIds)
inline

Adds members to the blocklist of this conversation.

Parameters
clientIdsMember list.
Returns
async Task<LCIMConversation> LeanCloud.Realtime.LCIMConversation.Fetch ( )
inline

Fetch conversation from server.

Returns
virtual async Task LeanCloud.Realtime.LCIMConversation.FetchReciptTimestamps ( )
inlinevirtual

Fetches receipt timestamp.

Returns

Reimplemented in LeanCloud.Realtime.LCIMChatRoom, and LeanCloud.Realtime.LCIMServiceConversation.

async Task<ReadOnlyCollection<LCIMConversationMemberInfo> > LeanCloud.Realtime.LCIMConversation.GetAllMemberInfo ( )
inline

Gets all member roles.

Returns
async Task<LCIMConversationMemberInfo> LeanCloud.Realtime.LCIMConversation.GetMemberInfo ( string  memberId)
inline

Gets the role of a specific member.

Parameters
memberIdThe member to query.
Returns
async Task<int> LeanCloud.Realtime.LCIMConversation.GetMembersCount ( )
inline

The count of members of this conversation.

Returns
async Task LeanCloud.Realtime.LCIMConversation.Join ( )
inline

Joins this conversation.

Returns
async Task LeanCloud.Realtime.LCIMConversation.Mute ( )
inline

Turns off the offline notifications of this conversation.

Returns
async Task<LCIMPartiallySuccessResult> LeanCloud.Realtime.LCIMConversation.MuteMembers ( IEnumerable< string >  clientIds)
inline

Mutes members of this conversation.

Parameters
clientIdsMember list.
Returns
async Task<LCIMPageResult> LeanCloud.Realtime.LCIMConversation.QueryBlockedMembers ( int  limit = 10,
string  next = null 
)
inline

Queries blocked members.

Parameters
limitLimits the number of returned results.
nextCan be used for pagination with the limit parameter.
Returns
async Task<ReadOnlyCollection<LCIMMessage> > LeanCloud.Realtime.LCIMConversation.QueryMessages ( LCIMMessageQueryEndpoint  start = null,
LCIMMessageQueryEndpoint  end = null,
LCIMMessageQueryDirection  direction = LCIMMessageQueryDirection.NewToOld,
int  limit = 20,
int  messageType = 0 
)
inline

Retrieves messages.

Parameters
startStart message ID.
endEnd message ID.
directionQuery direction (defaults to NewToOld).
limitLimits the number of returned results. Its default value is 100.
messageTypeThe message type to query. The default value is 0 (text message).
Returns
async Task<LCIMPageResult> LeanCloud.Realtime.LCIMConversation.QueryMutedMembers ( int  limit = 10,
string  next = null 
)
inline

Queries muted members.

Parameters
limitLimits the number of returned results.
nextCan be used for pagination with the limit parameter.
Returns
async Task LeanCloud.Realtime.LCIMConversation.Quit ( )
inline

Leaves this conversation.

Returns
virtual async Task LeanCloud.Realtime.LCIMConversation.Read ( )
inlinevirtual

Mark the last message of this conversation as read.

Returns

Reimplemented in LeanCloud.Realtime.LCIMChatRoom.

async Task LeanCloud.Realtime.LCIMConversation.RecallMessage ( LCIMMessage  message)
inline

Recalls a sent message.

Parameters
messageThe message to recall.
Returns
async Task<LCIMPartiallySuccessResult> LeanCloud.Realtime.LCIMConversation.RemoveMembers ( IEnumerable< string >  removeIds)
inline

Removes members from this conversation.

Parameters
removeIdsMember list.
Returns
async Task<LCIMMessage> LeanCloud.Realtime.LCIMConversation.Send ( LCIMMessage  message,
LCIMMessageSendOptions  options = null 
)
inline

Sends a message in this conversation.

Parameters
messageThe message to send.
optionsThe options of sending message.
Returns
async Task<LCIMPartiallySuccessResult> LeanCloud.Realtime.LCIMConversation.UnblockMembers ( IEnumerable< string >  clientIds)
inline

Removes members from the blocklist of this conversation.

Parameters
clientIdsMember list.
Returns
async Task LeanCloud.Realtime.LCIMConversation.Unmute ( )
inline

Turns on the offline notifications of this conversation.

Returns
async Task<LCIMPartiallySuccessResult> LeanCloud.Realtime.LCIMConversation.UnmuteMembers ( IEnumerable< string >  clientIds)
inline

Unmutes members of this conversation.

Parameters
clientIdListMember list.
Returns
async Task LeanCloud.Realtime.LCIMConversation.UpdateInfo ( Dictionary< string, object >  attributes)
inline

Update attributes of this conversation.

Parameters
attributesAttributes to update.
Returns
async Task LeanCloud.Realtime.LCIMConversation.UpdateMemberRole ( string  memberId,
string  role 
)
inline

Updates the role of a member of this conversation.

Parameters
memberIdThe member to update.
roleThe new role of the member.
Returns
async Task LeanCloud.Realtime.LCIMConversation.UpdateMessage ( LCIMMessage  oldMessage,
LCIMMessage  newMessage 
)
inline

Updates a sent message.

Parameters
oldMessageThe message to update.
newMessageThe updated message.
Returns

Property Documentation

LCIMClient LeanCloud.Realtime.LCIMConversation.Client
getprotected
DateTime LeanCloud.Realtime.LCIMConversation.CreatedAt
getset

The created date of this conversation.

string LeanCloud.Realtime.LCIMConversation.CreatorId
getset

The creator of this conversation.

string LeanCloud.Realtime.LCIMConversation.Id
getset

The ID of this conversation

bool LeanCloud.Realtime.LCIMConversation.IsMute
get

Indicates whether offline notifications about this conversation has been muted.

DateTime LeanCloud.Realtime.LCIMConversation.LastDeliveredAt
get

The last date of the delivered message.

long LeanCloud.Realtime.LCIMConversation.LastDeliveredTimestamp
getset

The last timestamp of the delivered message.

LCIMMessage LeanCloud.Realtime.LCIMConversation.LastMessage
getset

The last message in this conversation.

DateTime LeanCloud.Realtime.LCIMConversation.LastReadAt
get

The last date of the message which has been read by other clients.

long LeanCloud.Realtime.LCIMConversation.LastReadTimestamp
getset

The last timestamp of the message which has been read by other clients.

ReadOnlyCollection<string> LeanCloud.Realtime.LCIMConversation.MemberIds
get

The members of this conversation.

ReadOnlyCollection<string> LeanCloud.Realtime.LCIMConversation.MutedMemberIds
get

Muted members of this conversation.

string LeanCloud.Realtime.LCIMConversation.Name
getset

The name of this conversation.

object LeanCloud.Realtime.LCIMConversation.this[string key]
getset

Custom attributes.

Parameters
keyCustom attribute name.
Returns
bool LeanCloud.Realtime.LCIMConversation.Unique
getset

Indicates whether this conversation is normal and unique. The uniqueness is based on the members when creating.

string LeanCloud.Realtime.LCIMConversation.UniqueId
getset

If this conversation is unique, then it will have a unique ID.

int LeanCloud.Realtime.LCIMConversation.Unread
getset

The count of the unread messages.

DateTime LeanCloud.Realtime.LCIMConversation.UpdatedAt
getset

The last updated date of this conversation.


The documentation for this class was generated from the following file: