UserService class Null safety

Constructors

UserService()
factory

Properties

hashCode int
The hash code for this object.
read-only, inherited
onBlackListChanged Stream<void>
read / write
onFriendAddedOrUpdated Stream<List<NIMFriend>>
read / write
onFriendDeleted Stream<List<String>>
read / write
onMuteListChanged Stream<void>
read / write
onUserInfoChange Stream<List<NIMUser>>
read-only
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

ackAddFriend({required String userId, bool isAgree = true}) Future<NIMResult<void>>
Approve/disapprove a friend request.
addFriend({required String userId, String? message, required NIMVerifyType verifyType}) Future<NIMResult<void>>
Add a friend.
addToBlackList(String userId) Future<NIMResult<void>>
deleteFriend({required String userId, bool includeAlias = true}) Future<NIMResult<void>>
Delete a friend.
fetchUserInfoList(List<String> userIdList) Future<NIMResult<List<NIMUser>>>
Get the information about multiple users from the cloud. You can get the information about up to 150 users at a time; if you need to get a large amount of data, please implement corresponding logic on the application layer to allow the application to get data in batches. Query the information about multiple users by userIdList (users' accounts).
getAllUserInfoAndroid() Future<NIMResult<List<NIMUser>>>
Batch get information about multiple users from the local database.
getBlackList() Future<NIMResult<List<String>>>
getFriend(String userId) Future<NIMResult<NIMFriend>>
Get the information about a fiend.
getFriendAccountsAndroid() Future<NIMResult<List<String>>>
Get all fiends' accounts.
getFriendList() Future<NIMResult<List<NIMFriend>>>
Get the fiend list.
getMuteList() Future<NIMResult<List<String>>>
getUserInfo(String userId) Future<NIMResult<NIMUser>>
Get the information about a user from the local database. Query the user information by userId.
getUserInfoListAndroid(List<String> userIdList) Future<NIMResult<List<NIMUser>>>
Get the information about multiple users from the local database. Query the information about multiple users by passing in userIdList (users' accounts).
isInBlackList(String userId) Future<NIMResult<bool>>
isMute(String userId) Future<NIMResult<bool>>
isMyFriend(String userId) Future<NIMResult<bool>>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited
removeFromBlackList(String userId) Future<NIMResult<void>>
searchAccountByAliasAndroid(String alias) Future<NIMResult<List<String>>>
Search accounts by alias.
searchFriendsByKeywordAndroid(String keyword) Future<NIMResult<List<NIMFriend>>>
Search fiends by keyword.
searchUserIdListByNick(String nick) Future<NIMResult<List<String>>>
Query users' accounts by users' nicknames. Query the account list through nick (the nickname of the user).
searchUserInfoListByKeyword(String keyword) Future<NIMResult<List<NIMUser>>>
Search users by keyword. keyword The keyword.
setMute({required String userId, required dynamic isMute}) Future<NIMResult<void>>
toString() String
A string representation of this object.
inherited
updateFriend({required String userId, required String alias}) Future<NIMResult<void>>
updateMyUserInfo(NIMUser user) Future<NIMResult<void>>
Update the current user's profile. Update the profile to user's value.

Operators

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