fetchMessage method

Future<FetchImapResult> fetchMessage(
  1. int messageSequenceId,
  2. String fetchContentDefinition, {
  3. Duration? responseTimeout,
})

Fetches a single message by the given definition.

messageSequenceId the message sequence ID of the desired message fetchContentDefinition the definition of what should be fetched from the message, for example (UID ENVELOPE HEADER[]), BODY[] or ENVELOPE, etc Specify a responseTimeout when a response is expected within the given time.

Implementation

Future<FetchImapResult> fetchMessage(
        int messageSequenceId, String fetchContentDefinition,
        {Duration? responseTimeout}) =>
    fetchMessages(
        MessageSequence.fromId(messageSequenceId), fetchContentDefinition,
        responseTimeout: responseTimeout);