分类: C/C++
2012-01-27 13:19:18
您的评价: |
VMime 是一个开源的用于处理电子邮件的 C++ 类库,支持 IMAP, POP 和 SMTP.
示例代码:
1 | vmime::utility::url url("smtp://smtp.gmail.com"); |
2 | vmime::ref tr = session->getTransport(url); |
3 | tr->setProperty("connection.tls", true); |
4 | tr->setProperty("auth.username", "gmail-login"); |
5 | tr->setProperty("auth.password", "gmail-password"); |
6 | tr->setProperty("options.need-authentication", true); |
7 | tr->setCertificateVerifier(yourCertificateVerifier); |
官方网站: