NIM C# SDK  6.3.0
NIM.Session Namespace Reference

Classes

class  SessionAPI
 
class  SessionChangedEventArgs
 
class  SessionInfo
 
class  SessionNativeMethods
 
class  SesssionInfoList
 

Enumerations

enum  NIMSessionType { NIMSessionType.kNIMSessionTypeP2P = 0, NIMSessionType.kNIMSessionTypeTeam = 1 }
 会话类型 More...
 
enum  NIMSessionCommand {
  NIMSessionCommand.kNIMSessionCommandAdd = 0, NIMSessionCommand.kNIMSessionCommandRemove = 1, NIMSessionCommand.kNIMSessionCommandRemoveAll = 2, NIMSessionCommand.kNIMSessionCommandRemoveAllP2P = 3,
  NIMSessionCommand.kNIMSessionCommandRemoveAllTeam = 4, NIMSessionCommand.kNIMSessionCommandMsgDeleted = 5, NIMSessionCommand.kNIMSessionCommandAllMsgDeleted = 6, NIMSessionCommand.kNIMSessionCommandAllP2PMsgDeleted = 7,
  NIMSessionCommand.kNIMSessionCommandAllTeamMsgDeleted = 8, NIMSessionCommand.kNIMSessionCommandUpdate = 9
}
 会话操作命令 More...
 

Functions

delegate void SessionChangeHandler (int rescode, SessionInfo result, int totalUnreadCounts)
 最近会话项更新通知的回调 More...
 
delegate void QueryRecentHandler (int totalUnreadCount, SesssionInfoList result)
 查询所有最近会话项的回调 More...
 
internal delegate void NimSessionChangeCbFunc (int rescode, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Utf8StringMarshaler))] string result, int total_unread_counts, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Utf8StringMarshaler))] string json_extension, IntPtr user_data)
 
internal delegate void NimSessionQueryRecentSessionCbFunc (int total_unread_count, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Utf8StringMarshaler))] string result, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Utf8StringMarshaler))] string json_extension, IntPtr user_data)
 

Enumeration Type Documentation

◆ NIMSessionCommand

会话操作命令

Enumerator
kNIMSessionCommandAdd 

添加会话项

kNIMSessionCommandRemove 

删除单个会话项

kNIMSessionCommandRemoveAll 

删除所有会话项

kNIMSessionCommandRemoveAllP2P 

删除所有点对点的会话项

kNIMSessionCommandRemoveAllTeam 

删除所有群的会话项

kNIMSessionCommandMsgDeleted 

单个会话项的消息已删除

kNIMSessionCommandAllMsgDeleted 

所有会话项的消息已删除

kNIMSessionCommandAllP2PMsgDeleted 

所有点对点会话项的消息已删除

kNIMSessionCommandAllTeamMsgDeleted 

所有群会话项的消息已删除

kNIMSessionCommandUpdate 

更新会话项

◆ NIMSessionType

会话类型

Enumerator
kNIMSessionTypeP2P 

个人,即点对点

kNIMSessionTypeTeam 

群组

Function Documentation

◆ NimSessionChangeCbFunc()

internal delegate void NIM.Session.NimSessionChangeCbFunc ( int  rescode,
[MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Utf8StringMarshaler))] string  result,
int  total_unread_counts,
[MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Utf8StringMarshaler))] string  json_extension,
IntPtr  user_data 
)

◆ NimSessionQueryRecentSessionCbFunc()

internal delegate void NIM.Session.NimSessionQueryRecentSessionCbFunc ( int  total_unread_count,
[MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Utf8StringMarshaler))] string  result,
[MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Utf8StringMarshaler))] string  json_extension,
IntPtr  user_data 
)

◆ QueryRecentHandler()

delegate void NIM.Session.QueryRecentHandler ( int  totalUnreadCount,
SesssionInfoList  result 
)

查询所有最近会话项的回调

Parameters
totalUnreadCount总的未读数目
result最近会话列表

◆ SessionChangeHandler()

delegate void NIM.Session.SessionChangeHandler ( int  rescode,
SessionInfo  result,
int  totalUnreadCounts 
)

最近会话项更新通知的回调

Parameters
rescode操作结果,成功200
result最近会话
totalUnreadCounts总的未读数目