1/* 2 * Copyright 2011, Haiku, Inc. All rights reserved. 3 * Copyright 2011, Clemens Zeidler <haiku@clemens-zeidler.de> 4 * Distributed under the terms of the MIT License. 5 */ 6#ifndef IMAP_LISTENER_H 7#define IMAP_LISTENER_H 8 9 10#include "MailProtocol.h" 11 12#include <String.h> 13 14 15class HaikuMailFormatFilter : public MailFilter { 16public: 17 HaikuMailFormatFilter(MailProtocol& protocol, 18 BMailAccountSettings* settings); 19 20 void HeaderFetched(const entry_ref& ref, 21 BFile* file); 22 void BodyFetched(const entry_ref& ref, BFile* file); 23 24 void MessageSent(const entry_ref& ref, 25 BFile* file); 26private: 27 status_t _SetFileName(const entry_ref& ref, 28 const BString& name); 29 BString _ExtractName(const BString& from); 30 31private: 32 int32 fAccountID; 33 BString fAccountName; 34 BString fOutboundDirectory; 35}; 36 37 38#endif // IMAP_LISTENER_H 39