You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by sg...@apache.org on 2010/10/27 14:51:56 UTC
svn commit: r1027946 -
/commons/proper/email/trunk/src/site/xdoc/userguide.xml
Author: sgoeschl
Date: Wed Oct 27 12:51:56 2010
New Revision: 1027946
URL: http://svn.apache.org/viewvc?rev=1027946&view=rev
Log:
Cleaning up the email sample to set the session specific properties first
Modified:
commons/proper/email/trunk/src/site/xdoc/userguide.xml
Modified: commons/proper/email/trunk/src/site/xdoc/userguide.xml
URL: http://svn.apache.org/viewvc/commons/proper/email/trunk/src/site/xdoc/userguide.xml?rev=1027946&r1=1027945&r2=1027946&view=diff
==============================================================================
--- commons/proper/email/trunk/src/site/xdoc/userguide.xml (original)
+++ commons/proper/email/trunk/src/site/xdoc/userguide.xml Wed Oct 27 12:51:56 2010
@@ -32,15 +32,14 @@
<source>
<![CDATA[
Email email = new SimpleEmail();
+email.setHostName("smtp.gmail.com");
email.setSmtpPort(587);
email.setAuthenticator(new DefaultAuthenticator("username", "password"));
-email.setDebug(false);
-email.setHostName("smtp.gmail.com");
+email.setTLS(true);
email.setFrom("user@gmail.com");
email.setSubject("TestMail");
email.setMsg("This is a test mail ... :-)");
email.addTo("foo@bar.com");
-email.setTLS(true);
email.send();
]]></source>
<p>