|
NIMSDK-iOS
|
#import <NIMIndexManagerProtocol.h>
构造函数 | |
| (void) | - syncMsgIndex:session:completion: |
| (void) | - queryMsgIndex:session:option:withMessage:completion: |
| (void) | - resetMsgIndex: |
| (void) | - addDelegate: |
| (void) | - removeDelegate: |
索引协议
| - (void) addDelegate: | (id< NIMIndexManagerDelegate >) | delegate |
添加索引委托
| delegate | 检索委托 |
| - (void) queryMsgIndex: | (nonnull NSString *) | text | |
| session: | (nullable NIMSession *) | session | |
| option: | (nullable NIMMsgIndexQueryOption *) | option | |
| withMessage: | (BOOL) | withMessage | |
| completion: | (nullable NIMQueryMsgIndexBlock) | completion | |
查询消息索引
| text | 查询文本 |
| session | 指定会话,不传表示所有 |
| option | 查询选项 |
| withMesssage | 是否查询消息 |
| completion | 完成回调 @discussion 老方向和新方向不代表消息产生时间,而是指存入本地的时间 |
| - (void) removeDelegate: | (id< NIMIndexManagerDelegate >) | delegate |
移除索引委托
| delegate | 检索委托 |
| - (void) resetMsgIndex: | (nullable NIMResetMsgIndexBlock) | completion |
重置消息索引
| completion | 完成回调 |
| - (void) syncMsgIndex: | (BOOL) | old | |
| session: | (nullable NIMSession *) | session | |
| completion: | (nullable NIMSyncMsgIndexBlock) | completion | |
同步消息索引
| old | 同步方向,YES往老方向,NO往新方向 |
| session | 指定会话,不传表示所有 |
| completion | 完成回调 @discussion 老方向和新方向不代表消息产生时间,而是指存入本地的时间 |