private static Notifier buildNotifier(String notifier) { return new SendNotification() .setApplication(application()) .setChosenNotifier(notifier) .initNotifier(); }
@Override protected void initNotifier() { if (this.notifier == null) { this.notifier = sendNotification .setApplication(MAVEN) .addConfigurationProperties(configuration.getNotifierProperties()) .initNotifier(); } }
private Notifier buildNotifier() { return new SendNotification() .setApplication(application()) .initNotifier(); }
@VisibleForTesting DiscoverableNotifier chooseNotifier() { Properties properties = configuration.get(); mergeConfigurations(properties); maySetNotifierFromPropertyConfiguration(properties); if (chosenNotifiers != null) { LOGGER.debug("Notifications will be send to: {} for application: {}.", chosenNotifiers, application); return provider.byName(chosenNotifiers, properties, application); } return defaultNotifier(properties); }
public SendNotificationNotifier() { this.sendNotification = new SendNotification(); }
/** * Build a {@link fr.jcgay.notification.Notifier}. * * @return notifier based on provided configuration. */ public Notifier initNotifier() { return chooseNotifier().init(); }
@VisibleForTesting DiscoverableNotifier chooseNotifier() { Properties properties = configuration.get(); mergeConfigurations(properties); maySetNotifierFromPropertyConfiguration(properties); if (chosenNotifiers != null) { LOGGER.debug("Notifications will be send to: {} for application: {}.", chosenNotifiers, application); return provider.byName(chosenNotifiers, properties, application); } return defaultNotifier(properties); }
/** * Build a {@link fr.jcgay.notification.Notifier}. * * @return notifier based on provided configuration. */ public Notifier initNotifier() { return chooseNotifier().init(); }