MockContactsApi class
Properties
-
hashCode
→ int
-
The hash code for this object.
no setterinherited
-
runtimeType
→ Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
add(String contactUserId)
→ Future<ChatResult<void>>
-
Adds a user to the contact list.
override
-
block(String userId)
→ Future<ChatResult<void>>
-
Blocks a user, hiding their messages and preventing contact.
override
-
getConversationMessages(String conversationId, {})
→ Future<ChatResult<ChatPaginatedResponse<ChatMessage>>>
-
Fetches messages by conversation ID (the underlying 1:1 room ID).
override
-
getDirectMessages(String contactUserId, {})
→ Future<ChatResult<ChatPaginatedResponse<ChatMessage>>>
-
Fetches direct message history with a contact.
override
-
getPresence(String contactUserId)
→ Future<ChatResult<ChatPresence>>
-
Gets the online presence of a contact.
override
-
list({CachePolicy? cachePolicy})
→ Future<ChatResult<ChatPaginatedResponse<ChatContact>>>
-
Lists the current user's contacts.
override
-
listBlocked({})
→ Future<ChatResult<ChatPaginatedResponse<String>>>
-
Lists all blocked user IDs.
override
-
noSuchMethod(Invocation invocation)
→ dynamic
-
Invoked when a nonexistent method or property is accessed.
inherited
-
remove(String contactUserId)
→ Future<ChatResult<void>>
-
Removes a user from the contact list.
override
-
sendDirectMessage(String contactUserId, {String? text, MessageType messageType = MessageType.regular, String? referencedMessageId, String? reaction, String? attachmentUrl, Map<String, dynamic>? metadata})
→ Future<ChatResult<ChatMessage>>
-
Sends a direct message to a contact (creates a 1:1 room if needed).
override
-
sendTyping(String contactUserId, {ChatActivity activity = ChatActivity.startsTyping})
→ Future<ChatResult<void>>
-
Sends a typing indicator to a contact's DM conversation.
override
-
toString()
→ String
-
A string representation of this object.
inherited
-
unblock(String userId)
→ Future<ChatResult<void>>
-
Unblocks a previously blocked user.
override