+ for (Attachment attachmentT : attachments.keySet()) {
+ Resource resourceT = attachments.get(attachmentT);
+ uploadAndAdd(attachmentT, resourceT);
+ }
+
+ }
+
+ protected void uploadAndAdd(Attachment attachment, Resource resource) {
+ attachmentUploader.upload(attachment, resource);
+ for (AttachmentsEnabled attachmentsEnabled : attachTo) {
+ attachmentsEnabled.addAttachment(attachment);
+ }