@Override public String toString() { try { return rawText(Locale.getDefault()); } catch (SystemFailureException err) { return '<' + err.getMessage() + '>'; } } }
@Override public String toString() { try { return rawText(Locale.getDefault()); } catch (SystemFailureException err) { return '<' + err.getMessage() + '>'; } } }
@Override public String toString() { try { return rawText(Locale.getDefault()); } catch (SystemFailureException err) { return '<' + err.getMessage() + '>'; } } }
/** * Get the localized text for the supplied locale, replacing the parameters in the text with those supplied. * * @param locale the locale, or <code>null</code> if the {@link Locale#getDefault() current (default) locale} should be used * @param arguments the arguments for the parameter replacement; may be <code>null</code> or empty * @return the localized text */ @Override public String text( Locale locale, Object... arguments ) { try { String rawText = rawText(locale == null ? Locale.getDefault() : locale); return StringUtil.createString(rawText, arguments); } catch (IllegalArgumentException err) { throw new IllegalArgumentException(CommonI18n.i18nRequiredToSuppliedParameterMismatch.text(id, i18nClass, err.getMessage())); } catch (SystemFailureException err) { return '<' + err.getMessage() + '>'; } }
/** * Get the localized text for the supplied locale, replacing the parameters in the text with those supplied. * * @param locale the locale, or <code>null</code> if the {@link Locale#getDefault() current (default) locale} should be used * @param arguments the arguments for the parameter replacement; may be <code>null</code> or empty * @return the localized text */ @Override public String text( Locale locale, Object... arguments ) { try { String rawText = rawText(locale == null ? Locale.getDefault() : locale); return StringUtil.createString(rawText, arguments); } catch (IllegalArgumentException err) { throw new IllegalArgumentException(CommonI18n.i18nRequiredToSuppliedParameterMismatch.text(id, i18nClass, err.getMessage())); } catch (SystemFailureException err) { return '<' + err.getMessage() + '>'; } }
/** * Get the localized text for the supplied locale, replacing the parameters in the text with those supplied. * * @param locale the locale, or <code>null</code> if the {@link Locale#getDefault() current (default) locale} should be used * @param arguments the arguments for the parameter replacement; may be <code>null</code> or empty * @return the localized text */ @Override public String text( Locale locale, Object... arguments ) { try { String rawText = rawText(locale == null ? Locale.getDefault() : locale); return StringUtil.createString(rawText, arguments); } catch (IllegalArgumentException err) { throw new IllegalArgumentException(CommonI18n.i18nRequiredToSuppliedParameterMismatch.text(id, i18nClass, err.getMessage())); } catch (SystemFailureException err) { return '<' + err.getMessage() + '>'; } }