/** * Send the supplied {@link Notification} using the wrapped * {@link ModelMBean} instance. * @param notification the {@link Notification} to be sent * @throws IllegalArgumentException if the supplied {@code notification} is {@code null} * @throws UnableToSendNotificationException if the supplied {@code notification} could not be sent */ @Override public void sendNotification(Notification notification) { Assert.notNull(notification, "Notification must not be null"); replaceNotificationSourceIfNecessary(notification); try { if (notification instanceof AttributeChangeNotification) { this.modelMBean.sendAttributeChangeNotification((AttributeChangeNotification) notification); } else { this.modelMBean.sendNotification(notification); } } catch (MBeanException ex) { throw new UnableToSendNotificationException("Unable to send notification [" + notification + "]", ex); } }
public void sendNotification(Notification notification) throws MBeanException { broadcaster.sendNotification(notification); }
/** * Send the supplied {@link Notification} using the wrapped * {@link ModelMBean} instance. * @param notification the {@link Notification} to be sent * @throws IllegalArgumentException if the supplied {@code notification} is {@code null} * @throws UnableToSendNotificationException if the supplied {@code notification} could not be sent */ @Override public void sendNotification(Notification notification) { Assert.notNull(notification, "Notification must not be null"); replaceNotificationSourceIfNecessary(notification); try { if (notification instanceof AttributeChangeNotification) { this.modelMBean.sendAttributeChangeNotification((AttributeChangeNotification) notification); } else { this.modelMBean.sendNotification(notification); } } catch (MBeanException ex) { throw new UnableToSendNotificationException("Unable to send notification [" + notification + "]", ex); } }
/** * Send the supplied {@link Notification} using the wrapped * {@link ModelMBean} instance. * @param notification the {@link Notification} to be sent * @throws IllegalArgumentException if the supplied {@code notification} is {@code null} * @throws UnableToSendNotificationException if the supplied {@code notification} could not be sent */ @Override public void sendNotification(Notification notification) { Assert.notNull(notification, "Notification must not be null"); replaceNotificationSourceIfNecessary(notification); try { if (notification instanceof AttributeChangeNotification) { this.modelMBean.sendAttributeChangeNotification((AttributeChangeNotification) notification); } else { this.modelMBean.sendNotification(notification); } } catch (MBeanException ex) { throw new UnableToSendNotificationException("Unable to send notification [" + notification + "]", ex); } }