loadMessages method

void loadMessages()

Retrieves ruut client's messages. If persistence is enabled RuutCallbacks.onPersistedMessagesRetrieved will be triggered with persisted messages. On successfully fetch from remote server RuutCallbacks.onMessagesRetrieved will be triggered

Implementation

void loadMessages() async {
  _repository.getPersistedMessages();
  await _repository.getMessages();
}