2019-07-28 10:31:56 +08:00
|
|
|
|
#pragma once
|
2017-06-02 14:47:24 +08:00
|
|
|
|
#include "../acl_cpp_define.hpp"
|
|
|
|
|
#include "../stdlib/string.hpp"
|
|
|
|
|
#include "mime_node.hpp"
|
2014-11-19 00:25:21 +08:00
|
|
|
|
|
2019-05-19 16:54:20 +08:00
|
|
|
|
#if !defined(ACL_MIME_DISABLE)
|
|
|
|
|
|
2014-11-19 00:25:21 +08:00
|
|
|
|
namespace acl {
|
|
|
|
|
|
|
|
|
|
class ACL_CPP_API mime_attach : public mime_node
|
|
|
|
|
{
|
|
|
|
|
public:
|
|
|
|
|
mime_attach(const char* emailFile, const MIME_NODE* node,
|
|
|
|
|
bool enableDecode = true, const char* toCharset = "gb2312",
|
|
|
|
|
off_t off = 0);
|
|
|
|
|
|
2019-07-07 13:27:58 +08:00
|
|
|
|
virtual ~mime_attach(void);
|
2014-11-19 00:25:21 +08:00
|
|
|
|
|
|
|
|
|
/**
|
2019-07-28 10:31:56 +08:00
|
|
|
|
* <EFBFBD><EFBFBD><EFBFBD>ø<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ļ<EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
* @return {const char*} <EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֵΪ NULL <EFBFBD><EFBFBD>˵<EFBFBD><EFBFBD>û<EFBFBD><EFBFBD><EFBFBD>ҵ<EFBFBD><EFBFBD>ļ<EFBFBD><EFBFBD><EFBFBD>
|
2014-11-19 00:25:21 +08:00
|
|
|
|
*/
|
2019-07-07 13:27:58 +08:00
|
|
|
|
const char* get_filename(void) const;
|
2014-11-19 00:25:21 +08:00
|
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
string m_filename;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
} // namespace acl
|
2019-05-19 16:54:20 +08:00
|
|
|
|
|
|
|
|
|
#endif // !defined(ACL_MIME_DISABLE)
|