Skip to content
This repository has been archived by the owner on Jan 5, 2022. It is now read-only.

marcosvidolin/messagefy

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
src
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Messagefy

Codacy Badge Build Status Download

This is a very small helper java library to easily build a JavaMail MIME object (javax.mail.internet.MimeMessage).

To add Messagefy on your project:

Messagefy is release by publishing in to the JCenter. So add the following configuration to your "build.gradle".

repositories {
    ...
    jcenter()
}

Maven:

<dependency>
	<groupId>com.vidolima</groupId>
	<artifactId>messagefy</artifactId>
	<version>1.1.1</version>
	<type>pom</type>
</dependency>

Gradle:

dependencies {
  compile 'com.vidolima:messagefy:1.1.1'
}

Getting started

Example:

 Messagefy messagefy = new Messagefy.Builder()
       .from("sender@sender.com")
       .to("vidolima@vidolima.com")
       .subject("Messagefy")
       .content("Hello Messagefy!")
       .build();
       
javaMailSender.send(messagefy.getMailMessage());

More Options

Attribute Type Description
attachment byte[] The file to be attached to the message.
attachmentMimeType String Attachment MIME type.
attachmentName String Attachment name. Default name is "Untitled".
ccList Collection List of "Cc" (carbon copy) recipients.
content String The Message's content to a Multipart object.
contentType String The Message's Content Type. Default content type is "text/html".
from String The sender e-mail.
senderName String The sender name.
subject String The Message's subject.
toList Collection List of "To" (primary) recipients.

License

Messagefy is released under the terms of the MIT License.

Contributors

About

✉️ This is a very small helper java library to easily build a JavaMail MIME object (javax.mail.internet.MimeMessage).

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages