commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 17543] - Add support for non-default resource bundles
Date Fri, 23 May 2003 00:01:27 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=17543>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=17543

Add support for non-default resource bundles





------- Additional Comments From apacheBugzilla@AMammenT.cotse.net  2003-05-23 00:01 -------
Perhaps this could be handled by making it possible to programatically supply 
a bundle name for expansion of arguments via the ValidatorResources?  If the 
bundle is not present in the resources, expansion is performed treating all 
keys as if the "resource" flag was set to false.  Setting a resource flag to 
true implies that a bundle will be supplied by the user of the framework via 
the validator resources.

I'd go further and ask whether complete localization needs to be built into 
the validation framework.  Is it necessary to use resource bundles at all?  
(Resource bundles are more constrained than properties/map in that they're 
accessed in a very specific manner - from the classpath.)  Wouldn't it be just 
as practical to simply require that the user of the framework supply a 
properties file as a validator resource which will then be used to obtain all 
the required values?  (Perhaps, if appropriate, the properties can be supplied 
in conjunction with a locale, and cached for future use).  This allows the 
resources to be loaded from any appropriate source (classpath, servlet 
context, application context, file, etc).  Note that the localized forms are 
found via the xml file which IS loaded in just such a manner - via an 
InputStream as a validator resource.  Further, note that it's fairly simply to 
transform a ResourceBundle into a Map, but not so simple to go the other way.

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message