我在需要整合客户端电子邮件的项目中工作,经过长时间的研究,我发现名为k-9的库做了这个功能
我尝试将其集成到我的应用中,我无法找到本文的任何文档
https://github.com/k9mail/k-9/wiki/ThirdPartyApplicationIntegration
我的应用程序中需要的功能,登录+阅读传入的电子邮件
我可以阅读收到的电子邮件投掷广播
public class MessageReceiver extends BroadcastReceiver {
public static final Uri k9Uri = Uri.parse("content://com.fsck.k9.messageprovider/inbox_messages/");
static String[] messages_projection = new String[] {
"_id",
"date",
"sender",
"subject",
"preview",
"account",
"uri",
"delUri"
};
@Override
public void onReceive(Context context, Intent intent) {
Cursor curSt = mContext.getContentResolver().query(k9Uri, messages_projection, null, null, null);
curSt.moveToFirst();
String preview = curSt.getString(curSt.getColumnIndex("preview"));
}
但是如何使用特定配置登录登录
任何人都可以帮助我如何进行登录,或者有人建议我使用另一个库