de.deepamehta.plugins.mail
Class ImageCidEmbedment

Show UML class diagram
java.lang.Object
  extended by de.deepamehta.plugins.mail.ImageCidEmbedment

 class ImageCidEmbedment
extends Object


Field Summary
private  FilesService fileService
           
private static Logger log
           
 
Constructor Summary
ImageCidEmbedment(FilesService fileService)
           
 
Method Summary
 String embedImage(org.apache.commons.mail.HtmlEmail email, URL url, String name)
          Embed any image type (external URL, file repository and plugin resource).
 org.jsoup.nodes.Document embedImages(org.apache.commons.mail.HtmlEmail email, String body)
          Embed all images of body.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

private static Logger log

fileService

private final FilesService fileService
Constructor Detail

ImageCidEmbedment

public ImageCidEmbedment(FilesService fileService)
Method Detail

embedImages

public org.jsoup.nodes.Document embedImages(org.apache.commons.mail.HtmlEmail email,
                                            String body)
                                     throws org.apache.commons.mail.EmailException,
                                            IOException
Embed all images of body.

Returns:
Document with CID replaced image source attributes.
Throws:
org.apache.commons.mail.EmailException
IOException

embedImage

public String embedImage(org.apache.commons.mail.HtmlEmail email,
                         URL url,
                         String name)
                  throws org.apache.commons.mail.EmailException
Embed any image type (external URL, file repository and plugin resource).

Returns:
CID of embedded image.
Throws:
org.apache.commons.mail.EmailException


Copyright © 2013. All Rights Reserved.