1/*2 * Copyright 2000-2004 The Apache Software Foundation.3 * 4 * Licensed under the Apache License, Version 2.0 (the "License");5 * you may not use this file except in compliance with the License.6 * You may obtain a copy of the License at7 * 8 * http://www.apache.org/licenses/LICENSE-2.09 * 10 * Unless required by applicable law or agreed to in writing, software11 * distributed under the License is distributed on an "AS IS" BASIS,12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.13 * See the License for the specific language governing permissions and14 * limitations under the License.15 */16packageorg.apache.jetspeed.services.customlocalization;
1718import java.util.Locale;
19import java.util.ResourceBundle;
2021import org.apache.turbine.services.localization.LocalizationService;
22import org.apache.turbine.util.RunData;
2324/***25 * Custom Localization allows for the localization properties to changed dynamically,26 * without shutting down the application server. 27 *28 * @author <a href="mailto:massimiliano.dessi@gruppoatlantis.it">Dessė Massimiliano</a>29 * @version $Id: CustomLocalizationService.java,v 1.5 2004/02/23 03:49:33 jford Exp $30 */31publicinterfaceCustomLocalizationServiceextends LocalizationService
32 {
33/***34 * Get the locale from the session first, then fallback to normal request headers.35 * 36 * @param data37 * @return Current locale based on state.38 */39 Locale getLocale(RunData data);
4041/***42 * Get the resource bundle given the state of the current request.43 * 44 * @param data45 * @return The matched resource bundled.46 */47 ResourceBundle getBundle(RunData data);
484950publicstaticfinal String SERVICE_NAME = "LocalizationService";
51publicstaticfinal String ACCEPT_LANGUAGE = "Accept-Language";
52 }