package com.vci.client.common;
|
|
import java.util.Locale;
|
|
import com.vci.client.ui.locale.LocaleDisplay;
|
|
public class BaseConfitUtils {
|
/**
|
* KEY,从远程服务器端conf.properties中配置值对应的Boolean类型值, 如果key配置的值等于true,则返回true,否则返回false
|
* <p>Description: </p>
|
*
|
* @author xchao
|
* @time 2013-3-20
|
* @param key
|
* @return
|
*/
|
public static boolean getBooleanConfigValue(String key){
|
return ConfigUtils.getConfigValue(key).equals("true");
|
}
|
|
/**
|
* 批回指定KEY,在RMIPFramework的国际化信息
|
* <p>Description: </p>
|
*
|
* @author xchao
|
* @time 2013-3-20
|
* @param key
|
* @return
|
*/
|
public static String getFramworkI18nString(String key){
|
return getI18nString(key, "RMIPFramework");
|
}
|
/**
|
* 根据指定的key, 在相应的国际化文件中取配置值
|
* <p>Description: </p>
|
*
|
* @author xchao
|
* @time 2013-3-20
|
* @param key key
|
* @param fileName 国际化文件名称(e.g:RMIPCode)
|
* @return
|
*/
|
public static String getI18nString(String key, String fileName){
|
return LocaleDisplay.getI18nString(key, fileName, Locale.getDefault());
|
}
|
|
}
|