Skip to main content

ChatService class

Provides different services for direct chats of the user.

Services include:

  • sendMessageToDirectChat - used to send messages.
  • getDirectChatsByUserId - used to get all chats by the user.
  • getDirectChatMessagesByChatId - gets all chats of a user with another user.

Constructors

ChatService

:

Properties

[chatListStream] [→ Stream[<[ChatListTileDataModel]>]] : Getter for chat list stream. ::: features no setter :::

[chatMessagesStream] [→ Stream[<[ChatMessage]>]] : Getter for chat messages stream. ::: features no setter :::

[chatStream] [↔ Stream[<[QueryResult[<[Object?]>]]>]] : Stream for GraphQL query results. ::: features getter/setter pair :::

[hashCode] [→ int] : The hash code for this object. ::: features no setterinherited :::

[runtimeType] [→ Type] : A representation of the runtime type of the object. ::: features no setterinherited :::

Methods

[getDirectChatMessagesByChatId]([[dynamic chatId]) [→ Future<[void>]] ] : This function retrieves direct chat messages by chat ID.

[getDirectChatsByUserId][ [→ Future<[void>]] ] : Retrieves direct chats by user ID.

[noSuchMethod][([[Invocation] invocation]) → dynamic ] : Invoked when a nonexistent method or property is accessed. ::: features inherited :::

[sendMessageToDirectChat][([[String] chatId, ][[String] messageContent]) [→ Future<[void>]] ] : Sends a message to a direct chat.

[toString][ [→ String] ] : A string representation of this object. ::: features inherited :::

Operators

[operator ==][([[Object] other]) [→ bool] ] : The equality operator. ::: features inherited :::

  1. talawa
  2. chat_service
  3. ChatService class
chat_service library