Uploaded image for project: 'James Mime4j'
  1. James Mime4j
  2. MIME4J-268

Helper method for message to bytes convertion

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 0.8.2
    • dom
    • None

    Description

      Current code looks like this:

          public byte[] asBytes(Message message) throws IOException {
              ByteArrayOutputStream buffer = new ByteArrayOutputStream();
              DefaultMessageWriter writer = new DefaultMessageWriter();
              writer.writeMessage(message, buffer);
              return buffer.toByteArray();
          }
      

      This is rather complicated for clients. I would propose to introduce that helper method in DefaultMessageWriter.

      Attachments

        Activity

          People

            Unassigned Unassigned
            btellier Benoit Tellier
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: