Hi all,
I am quite new to the Turbine framework. I would like to use the mail
API located in the org.apache.turbine.util.mail package.
I have discovered that this API has an extensive use of the Criteria
class. This way is, I thing, not natural for creating emails but I may
miss something.
So, I have done a little rewrite work. Basically, instead of using a
Criteria, on should use the setFrom, addTo, etc. methods of the new
Email class. I have also adapted the WebMacro Email utilities to match
the new design. Obviously, my classes are backward compatible, but the
constructors like SimpleEmail(Criteria criteria) are marked as
deprecated. Here are the summary of the changes:
Email.java: new methods (setFrom, addTo, etc.)
EmailAttachement: nothing new
SimpleEmail: constructor SimpleEmail(). setMsg method()
MultipartEmail: new methods attach(...) that allow to attach URLs
WebMacroEmail: rewrite for not using deprecated API
I have also added two classes for sending HTML formatted email.These
classes allow to embed inline images. HtmlEmail that extends
MultiPartEmail and WebMacroHtmlEmail that can use a template for the
HTML content.
May be I am wrong in chnaging the design and I will keep my changes for
me. If not, they may be usefull for other developpers, so I can post the
new package.
regards
Regis
------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?: [EMAIL PROTECTED]