# MailSender **Repository Path**: VeiZhang/MailSender ## Basic Information - **Project Name**: MailSender - **Description**: 邮箱发送 - **Primary Language**: Java - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2019-07-29 - **Last Updated**: 2020-12-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # MailSender发送邮件 [![Download][icon_download]][download] ``` dependencies { compile 'com.excellence:mailsender:_latestVersion' } ``` 使用JavaMail-Android:additional.jar、activation.jar、mail.jar ###### 示例 ``` MailSender mailSender = new MailSender("xx发送邮箱xx", "**密码**"); mailSender.setFrom("xx发送邮箱xx"); mailSender.setTo(new String[] { "xx接收邮箱1xx", "xx接收邮箱2xx" }); mailSender.setSubject("xx标题xx"); mailSender.setBody("xx邮件内容xx"); mailSender.addAttachment("xx附件路径xx", "xx附件文件名xx"); // 是否发送成功 boolean result = mailSender.send(); ``` ## 使用说明 * 允许群发邮件 * 不能在主进程中使用 * 发送邮箱、密码,接收邮箱、标题、内容均不可为空 ## 测试成功 * 新浪邮箱 ## 版本更新 | 版本 | 描述 | |------------------------- | -------------------------------------------------------------- | | [1.0.0][MailSenderV1.0.0] | 发送邮件 **2017-7-27** | [download]:https://bintray.com/veizhang/maven/mailsender/_latestVersion "Latest version" [icon_download]:https://api.bintray.com/packages/veizhang/maven/mailsender/images/download.svg [MailSenderV1.0.0]:https://bintray.com/veizhang/maven/mailsender/1.0.0