@Test public void testWithOneParameter() throws Exception { String value = "this"; Assert.assertEquals(expected, MSG.get("test.with.1.parameter", value)); }
public String get(String key) { if (bundle == null) { return String.format("Key '%s' not found in bundle '%s' and locale '%s'", key, name, locale.toString()); } try { return bundle.getString(key); } catch (MissingResourceException e) { return String.format("Key '%s' not found in bundle '%s' and locale '%s'", key, name, locale.toString()); } }
Messages { public String get(String key) { if (bundle == null) { return String.format("Key '%s' not found in bundle '%s' and locale '%s'", key, name, locale.toString()); } try { return bundle.getString(key); } catch (MissingResourceException e) { return String.format("Key '%s' not found in bundle '%s' and locale '%s'", key, name, locale.toString()); } } }
Messages { public String get(String key) { if (bundle == null) { return String.format("Key '%s' not found in bundle '%s' and locale '%s'", key, name, locale.toString()); } try { return bundle.getString(key); } catch (MissingResourceException e) { return String.format("Key '%s' not found in bundle '%s' and locale '%s'", key, name, locale.toString()); } } Messages();  Messages(String name);  Messages(String name, Locale locale); }
Messages { public String get(String key) { if (bundle == null) { return String.format("Key '%s' not found in bundle '%s' and locale '%s'", key, name, locale.toString()); } try { return bundle.getString(key); } catch (MissingResourceException e) { return String.format("Key '%s' not found in bundle '%s' and locale '%s'", key, name, locale.toString()); } } Messages();  Messages(String name);  Messages(String name, Locale locale); String get(String key); String get(String key, Object ... args); }
Messages { public String get(String key) { if (bundle == null) { return String.format("Key '%s' not found in bundle '%s' and locale '%s'", key, name, locale.toString()); } try { return bundle.getString(key); } catch (MissingResourceException e) { return String.format("Key '%s' not found in bundle '%s' and locale '%s'", key, name, locale.toString()); } } Messages();  Messages(String name);  Messages(String name, Locale locale); String get(String key); String get(String key, Object ... args);  }