/**
  * Gets the list of emails each one separated by a comma.
  *
  * @return the list of emails each one separated by a comma.
  */
 public String getEmailsSeparatedByComma() {
   String comma = ",";
   StringBuilder sb = new StringBuilder(30 * size());
   for (MailAddress mailAddress : this) {
     if (sb.length() > 0) {
       sb.append(comma);
     }
     sb.append(mailAddress.getEmail());
   }
   return sb.toString();
 }
Exemplo n.º 2
0
 /**
  * Sets one or more TO address. Address may be specified with personal name like this: <code>
  * "Jenny Doe &lt;[email protected]&gt;</code>.
  */
 public Email to(String[] tos) {
   setTo(MailAddress.createFrom(tos));
   return this;
 }
Exemplo n.º 3
0
 /** Sets one or more BCC addresses. */
 public Email bcc(String[] bccs) {
   setBcc(MailAddress.createFrom(bccs));
   return this;
 }
Exemplo n.º 4
0
 /** Sets one or more BCC addresses. */
 public Email bcc(InternetAddress[] bccs) {
   setBcc(MailAddress.createFrom(bccs));
   return this;
 }
Exemplo n.º 5
0
 /** Sets one or more CC address. */
 public Email cc(InternetAddress[] ccs) {
   setCc(MailAddress.createFrom(ccs));
   return this;
 }
Exemplo n.º 6
0
 /**
  * Sets one or more CC address. Address may be specified with personal name like this: <code>
  * "Jenny Doe &lt;[email protected]&gt;</code>.
  */
 public Email cc(String[] ccs) {
   setCc(MailAddress.createFrom(ccs));
   return this;
 }
Exemplo n.º 7
0
 /** Sets one or more REPLY-TO address. */
 public Email replyTo(InternetAddress[] replyTos) {
   setReplyTo(MailAddress.createFrom(replyTos));
   return this;
 }
Exemplo n.º 8
0
 /**
  * Sets one or more REPLY-TO address. Address may be specified with personal name like this:
  * <code>"Jenny Doe &lt;[email protected]&gt;</code>.
  */
 public Email replyTo(String[] replyTos) {
   setReplyTo(MailAddress.createFrom(replyTos));
   return this;
 }
Exemplo n.º 9
0
 /** Sets one or more TO addresses. */
 public Email to(InternetAddress[] tos) {
   setTo(MailAddress.createFrom(tos));
   return this;
 }