use of com.synopsys.integration.alert.service.email.enumeration.EmailPropertyKeys in project hub-alert by blackducksoftware.
the class JavamailPropertiesFactory method createJavaMailProperties.
@Deprecated(forRemoval = true)
public Properties createJavaMailProperties(FieldUtility fieldUtility) {
if (fieldUtility == null) {
throw new IllegalArgumentException("Could not find the global Email configuration");
}
Properties javaMailProperties = new Properties();
for (EmailPropertyKeys emailPropertyKey : EmailPropertyKeys.values()) {
String key = emailPropertyKey.getPropertyKey();
String value = fieldUtility.getStringOrEmpty(key);
if (StringUtils.isNotBlank(value)) {
javaMailProperties.setProperty(key, value);
}
}
return javaMailProperties;
}
Aggregations