方法重载问题
不同的java环境或者不同的javac参数使得 使用重载的class编译出不同的结果
?
?public static FacesMessage createFacesMessage( String key,Object... params)
{
??return FacesMessages.createFacesMessage(FacesMessage.SEVERITY_ERROR,key, key, params
}
?
?public static FacesMessage createFacesMessage( String key,String messageTemplate,Object... params)
{
??return FacesMessages.createFacesMessage(FacesMessage.SEVERITY_ERROR,key, messageTemplate, params);
?}
如下使用方式编译出两种class
MessageBundleUtil.createFacesMessage("number.required",label))
?
MessageBundleUtil.createFacesMessage("number.required",new Objece{label}))
MessageBundleUtil.createFacesMessage("number.required",label,new Objece{}))
?
去掉createFacesMessage( String key,Object... params) 方法
使用方式MessageBundleUtil.createFacesMessage("number.required",null,label))