LocalizableObject implements Localizable { public boolean supportsLanguage(Language language) { if (language == null) throw new IllegalArgumentException("Language must not be null"); return languages.contains(language); } LocalizableObject();  LocalizableObject(Language defaultLanguage); void addLocalizationListener(LocalizationListener listener); void removeLocalizationListener(LocalizationListener listener); void enableLanguage(Language language); void disableLanguage(Language language); Language switchTo(Language language); Language switchTo(Language language, boolean force); Language getLanguage(); void setLanguageResolution(LanguageResolution behavior); LanguageResolution getLanguageResolution(); void setDefaultLanguage(Language language); Language getDefaultLanguage(); Language getOriginalLanguage(); void setOriginalLanguage(Language language); boolean supportsLanguage(Language language); Set<Language> languages(); int compareTo(Localizable o, Language l); String toString(); String toString(Language language); String toString(Language language, boolean force);  }
@Test public void testSupportsLanguage() { assertTrue(content.supportsLanguage(english)); assertFalse(content.supportsLanguage(italian)); LocalizableObject lc = new LocalizableContent<String>(); lc.setOriginalLanguage(english); lc.setDefaultLanguage(french); assertFalse(lc.supportsLanguage(english)); assertFalse(lc.supportsLanguage(french)); }