1 package org.apache.turbine.services.localization; 2 3 18 19 import java.util.Locale ; 20 import java.util.ResourceBundle ; 21 import javax.servlet.http.HttpServletRequest ; 22 23 import org.apache.turbine.services.Service; 24 25 41 public interface LocalizationService 42 extends Service 43 { 44 47 String SERVICE_NAME = "LocalizationService"; 48 49 52 String ACCEPT_LANGUAGE = "Accept-Language"; 53 54 58 String getDefaultLanguage(); 59 60 64 String getDefaultCountry(); 65 66 71 String getDefaultBundleName(); 72 73 80 String [] getBundleNames(); 81 82 87 ResourceBundle getBundle(); 88 89 96 ResourceBundle getBundle(String bundleName); 97 98 106 ResourceBundle getBundle(String bundleName, String languageHeader); 107 108 116 ResourceBundle getBundle(HttpServletRequest req); 117 118 127 ResourceBundle getBundle(String bundleName, HttpServletRequest req); 128 129 137 ResourceBundle getBundle(String bundleName, Locale locale); 138 139 149 Locale getLocale(HttpServletRequest req); 150 151 159 Locale getLocale(String languageHeader); 160 161 166 void setBundle(String defaultBundle); 167 168 178 String getString(String bundleName, Locale locale, String key); 179 180 } 181 | Popular Tags |