S
S
Shadrindmitry2020-05-28 01:17:06
Android
Shadrindmitry, 2020-05-28 01:17:06

How to properly process and display a sent message in a chat?

I am writing a chat application using the paging library. When the user sends a message, I want to instantly output it to the adapter. To do this, it must be saved to a local database in order to stream the datasource. Then, when the server processes the message, it will return it with a valid ID. What is the correct way to overwrite a message received from the server into local storage so that there are no duplicates?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question