-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Hi guys,
I read the page http://books.zkoss.org/wiki/ZK_Developer%27s_Reference/Internationalization/Labels that talks abut using
LabelLocator2 to do i18n from database BUT the example it gave is like
public class FooDBLocator extends org.zkoss.util.resource.LabelLocator2 { private String _field; public FooDBLocator(String field) { _field = field; } public InputStream locate(Locale locale) { InputStream is = ... //load the properties from, say, database return is; } public String getCharset() { return "UTF-8"; //depending the encoding you use } }
Does anyone have a more solid example of how to construct the inputstream in locate(..) above?
Thanks,
Sam
Asked: 2012-01-19 22:17:09 +0800
Seen: 131 times
Last updated: Apr 19 '13