MessageNotification messageNotification = new MessageNotification(settings, notificationEmail);
return messageNotification.getNotifications();
}
private InsertCorrespondenceV2 createRequest(CorrespondenceMessage msg, String notificationEmail) {
InsertCorrespondenceV2 insertCorrespondence = new InsertCorrespondenceV2();
insertCorrespondence.setServiceCode(settings.getServiceCode());
insertCorrespondence.setServiceEdition(settings.getServiceEdition());
insertCorrespondence.setAllowForwarding(false);
insertCorrespondence.setReportee(msg.getOrgNr());
insertCorrespondence.setVisibleDateTime(XMLDatatypeUtil.toXMLGregorianCalendar(Calendar.getInstance()));
insertCorrespondence.setNotifications(createMessageNotification(notificationEmail));
return insertCorrespondence;
}