IMManager class

Constructors

IMManager(MethodChannel _channel)

Properties

channel MethodChannel
no setter
conversationManager ConversationManager
getter/setter pair
friendshipManager FriendshipManager
getter/setter pair
groupManager GroupManager
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
isLogined bool
getter/setter pair
messageManager MessageManager
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
token String?
getter/setter pair
userID String
getter/setter pair
userInfo UserInfo
getter/setter pair
userManager UserManager
getter/setter pair

Methods

getLoginStatus({String? operationID}) Future<int?>
Get login status 1: logout 2: logging 3: logged
getLoginUserID() Future<String>
Get the current logged-in user ID
getLoginUserInfo() Future<UserInfo>
Get the current logged-in user information
init(InitConfig config, OnConnectListener listener, {String? operationID}) Future<bool?>
initSDK({required int platformID, required String apiAddr, required String wsAddr, required String dataDir, required OnConnectListener listener, int logLevel = 6, bool isNeedEncryption = false, bool isCompression = false, bool isLogStandardOutput = true, String? logFilePath, String? operationID}) Future
Initialize the SDK platform Platform ID IMPlatform apiAddr SDK API address wsAddr SDK WebSocket address dataDir SDK database storage directory logLevel Log level, 1: no printing enabledEncryption true: encryption enabledCompression true: compression
login({required String userID, required String token, String? operationID, Future<UserInfo> defaultValue()?, bool checkLoginStatus = true}) Future<UserInfo>
Login userID User ID token Login token obtained from the business server defaultValue Default value to use if login fails
logout({String? operationID}) Future
Logout
logs({int logLevel = 5, String? file, int line = 0, String? msgs, String? err, List? keyAndValues, String? operationID}) Future
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
setListenerForService(OnListenerForService listener) Future
setUploadFileListener(OnUploadFileListener listener) → void
setUploadLogsListener(OnUploadLogsListener listener) → void
toString() String
A string representation of this object.
inherited
unInitSDK() Future
Deinitialize the SDK
updateFcmToken({required String fcmToken, required int expireTime, String? operationID}) Future
Update the Firebase client registration token fcmToken Firebase token
uploadFile({required String id, required String filePath, required String fileName, String? contentType, String? cause, String? operationID}) Future
id Same as OnUploadFileListener ID, to distinguish which file callback it is
uploadLogs({String? ex, int line = 0, String? operationID}) Future
Upload logs

Operators

operator ==(Object other) bool
The equality operator.
inherited