NADEE-MJ / fax_app_cli

GNU General Public License v3.0
0 stars 0 forks source link

[FEATURE] Sync and get messages #7

Closed NADEE-MJ closed 2 years ago

NADEE-MJ commented 2 years ago

Is your feature request related to a problem? Please describe. Sync with server to update all rooms and messages/get users current state and also ability to get messages from a single room, including older messages.

Describe the solution you'd like

Additional context Matrix Client-Server API

NADEE-MJ commented 2 years ago

Here are the changes I have made in the initial commit:

  1. added sync and messages commands in main.dart. It is probably not a good place but is good for testing.
  2. Fixed requester class: getRequest can now send requests with data, uses params in the link instead of passing them into the http client like the other methods in the class
  3. added sync and getNewMessages to the user class, still a work in progress, but they are both currently are working however the data is not going anywhere.
  4. simplified UserInfo class and moved some functionality into a JsonFileHandler class, also added some new attributes to store info for syncing and getting messages.
  5. Added MessageUpdate and MessageInfo to store new messages received from sync and getNewMessages api calls.
NADEE-MJ commented 2 years ago

solved with pr #19, all features from this issue have been added and I am now closing the issue, still need to write tests for it. That is the next major step we need to take.

We also need to start using test-driven development so that we can find errors before we make them.