onProgress
Feature Introduction
info
Message sending progress callback, typically used when sending file-type messages.
- iOS
- Android
- Flutter
- uni-app
- Browser/Electron/MiniProgram
Return Prototype
Function(String clientMsgID, int progress)? onProgress;
Return Result
Name | Type | Description |
---|---|---|
clientMsgID | String | Message ID |
progress | int | Progress value |
Return Prototype
typedef void (^OIMNumberCallback)(NSInteger number);
Return Result
Name | Type | Description |
---|---|---|
number | NSInteger | Progress value |
### Return Prototype
void onProgress(long progress)
Return Result
Name | Type | Description |
---|---|---|
progress | long | Message send progress |
Message Sending Progress Callback
onProgress(data: WSEvent<number>): void;
Example Call
import { getSDK, CbEvents } from '@openim/wasm-client-sdk';
// or
// import { OpenIMSDK, CbEvents } from 'open-im-sdk';
// const IMSDK = new OpenIMSDK();
const IMSDK = getSDK();
IMSDK.on(CbEvents.OnProgress, ({ data }) => {
// data Message send progress
});