Commons Email
  1. Commons Email
  2. EMAIL-114

Methods to add multiple To, cc, Bcc is desired

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.3
    • Labels:
      None

      Description

      Currently if we have list of email address as string adding them to mail is possible only by looping or converting them as list of java.mail.internet.InternetAddress.

      Method like addTo(String[] emails) is desired.

        Activity

        Hide
        Thomas Neidhart added a comment -

        I tried to be consistent with the existing setXXX methods, and the EmailException is already thrown atm, but I agree, an IAE would be more logical.

        Show
        Thomas Neidhart added a comment - I tried to be consistent with the existing setXXX methods, and the EmailException is already thrown atm, but I agree, an IAE would be more logical.
        Hide
        Jochen Wiedmann added a comment -

        May I suggest that an IllegalArgumentException would be preferrable, so that we son't pollute the signature without need?

        Show
        Jochen Wiedmann added a comment - May I suggest that an IllegalArgumentException would be preferrable, so that we son't pollute the signature without need?
        Hide
        Thomas Neidhart added a comment -

        Applied patch with minor changes in r1416248:

        • throw an EmailException if the supplied array is null or empty
        • minor javadoc changes

        Thanks for the report and patch!

        Show
        Thomas Neidhart added a comment - Applied patch with minor changes in r1416248: throw an EmailException if the supplied array is null or empty minor javadoc changes Thanks for the report and patch!
        Hide
        Gokul Nanthakumar C added a comment -

        Patch for new Methods addTo(String[]), addCc(String[]), addBcc(String[])

        Show
        Gokul Nanthakumar C added a comment - Patch for new Methods addTo(String[]), addCc(String[]), addBcc(String[])

          People

          • Assignee:
            Unassigned
            Reporter:
            Gokul Nanthakumar C
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development