fetchThreadData method

Future<ThreadDataResult> fetchThreadData({
  1. Mailbox? mailbox,
  2. required DateTime since,
  3. bool setThreadSequences = false,
})

Retrieves thread information starting at since.

When you set setThreadSequences to true, then the MimeMessage.threadSequence will be populated automatically for future fetched mesages. Optionally specify the mailbox, in case not the currently selected mailbox should be used. Compare supportsThreading.

Implementation

Future<ThreadDataResult> fetchThreadData({
  Mailbox? mailbox,
  required DateTime since,
  bool setThreadSequences = false,
}) {
  mailbox ??= _selectedMailbox;
  if (mailbox == null) {
    throw StateError('no mailbox defined nor selected');
  }
  return _incomingMailClient.fetchThreadData(
      mailbox, since, setThreadSequences);
}