*/ public function capabilities(): array; /** * Unsuccessful command completion throws ImapException. For streamed * results, completion is checked as the returned generator is consumed. * * @throws ImapException * @template TResult * @param CommandInterface $command * @return TResult */ public function perform(CommandInterface $command): mixed; /** * Stream the raw bytes of a single IMAP BODY section without buffering. * * @return \Generator raw (transfer-encoded) bytes from the socket */ public function download(MessageTarget $target, string $section, int $chunkSize = 8192): \Generator; }