JavaでAttachmentをByteArrayに変換する方法は?
JavaでAttachmentオブジェクトを作成し、それにPDFを添付しました。これがコードです
ByteArrayInputStream pdfStream = null;
pdfStream = new ByteArrayInputStream(bytes);
AttachmentImpl pdfAttachment = new AttachmentImpl("application/pdf",pdfStream);
誰かが添付ファイルからbytearryを取り戻す方法を教えてもらえますか?