프로젝트
GitHub에서 보기
andyedinborough/aenetmail
소개
C# POP/IMAP Mail Client
생산성 및 자동화측정된 스타 증가
- in 24h
- 0
- in 7 days
- 0
- in 15 days
- 0
- in 1 month
- 기록 수집 중
서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.
README.md
OriginalAE.Net.Mail
A C# POP/IMAP client library
Background
These are text-based services... it's not that hard, and yet all the projects I found out there were nasty, bloated, and severely error prone. So, I rebuilt one. This is based heavily on xemail-net. I simplified it quite a bit, and created standard methods for repeated code blocks and implemented a base class to simplify the creation of the Pop3 client.
Sample Usage
IMAP
using(var imap = new AE.Net.Mail.ImapClient(host, username, password, AE.Net.Mail.ImapClient.AuthMethods.Login, port, isSSL)) {
var msgs = imap.SearchMessages(
SearchCondition.Undeleted().And(
SearchCondition.From("david"),
SearchCondition.SentSince(new DateTime(2000, 1, 1))
).Or(SearchCondition.To("andy"))
);
Assert.AreEqual(msgs[0].Value.Subject, "This is cool!");
imap.NewMessage += (sender, e) => {
var msg = imap.GetMessage(e.MessageCount - 1);
Assert.AreEqual(msg.Subject, "IDLE support? Yes, please!");
};
}
POP
using(var pop = new AE.Net.Mail.Pop3Client(host, username, password, port, isSSL)) {
for(var i = pop.GetMessageCount() - 1; i >= 0; i--){
var msg = pop.GetMessage(i, false);
Assert.AreEqual(msg.Subject, "Standard API between different protocols? Yes, please!");
pop.DeleteMessage(i); //WE DON'T NEED NO STINKIN' EMAIL!
}
}
Installation
Install-Package AE.Net.Mail
License
관련 프로젝트 살펴보기
불러오는 중…