@Override public String getNotificationDescription(String notificationType, Locale locale, ResourceBundle bundle) { for (PathElement path : this.paths) { String key = this.getBundleKey(path, notificationType); if (bundle.containsKey(key)) { return bundle.getString(key); } } return this.parent.getNotificationDescription(notificationType, locale, bundle); }
@Override public String getNotificationDescription(String notificationType, Locale locale, ResourceBundle bundle) { for (PathElement path : this.paths) { String key = this.getBundleKey(path, notificationType); if (bundle.containsKey(key)) { return bundle.getString(key); } } return this.parent.getNotificationDescription(notificationType, locale, bundle); }
@Override public ModelNode getModelDescription(Locale locale) { ModelNode result = new ModelNode(); final ResourceBundle bundle = descriptionResolver.getResourceBundle(locale); result.get(NOTIFICATION_TYPE).set(notificationType); result.get(DESCRIPTION).set(descriptionResolver.getNotificationDescription(notificationType, locale, bundle)); if (dataValueDescriptor != null) { ModelNode dataDescription = dataValueDescriptor.describe(bundle); if (dataDescription != null && dataDescription.isDefined()) { result.get(NOTIFICATION_DATA_TYPE).set(dataDescription); } } return result; } }
@Override public ModelNode getModelDescription(Locale locale) { ModelNode result = new ModelNode(); final ResourceBundle bundle = descriptionResolver.getResourceBundle(locale); result.get(NOTIFICATION_TYPE).set(notificationType); result.get(DESCRIPTION).set(descriptionResolver.getNotificationDescription(notificationType, locale, bundle)); if (dataValueDescriptor != null) { ModelNode dataDescription = dataValueDescriptor.describe(bundle); if (dataDescription != null && dataDescription.isDefined()) { result.get(NOTIFICATION_DATA_TYPE).set(dataDescription); } } return result; } }
@Override public ModelNode getModelDescription(Locale locale) { ModelNode result = new ModelNode(); final ResourceBundle bundle = descriptionResolver.getResourceBundle(locale); result.get(NOTIFICATION_TYPE).set(notificationType); result.get(DESCRIPTION).set(descriptionResolver.getNotificationDescription(notificationType, locale, bundle)); if (dataValueDescriptor != null) { ModelNode dataDescription = dataValueDescriptor.describe(bundle); if (dataDescription != null && dataDescription.isDefined()) { result.get(NOTIFICATION_DATA_TYPE).set(dataDescription); } } return result; } }