From: Alistair Y. <ali...@sm...> - 2005-07-14 09:35:43
|
yep, no way round that. literals are passed to Facility methods so I can't pass a Localiser method call instead of a string. It has to be a java.lang.String that gets passed to Facility. It's a fundamental i18n limitation of bod. You need to recompile the template if you change a Facility literal string in a properties file. For all other "normal" content, i.e. content that the template class displays, you don't need to recompile if you change the properties file. Templates delegating content display to Facility causes the problem. Alistair On 14 Jul 2005, at 10:28, Matthew Buckett wrote: > Alistair Young wrote: > >>> So you hardcode the resource >>> properties in the .java file that the compiler produces? >>> >> yes. There was a debate ages ago whether to substitute a <localise> >> element with the actual text or write code into the template class to >> dynamically call the Localiser. We choose the dynamic method as >> that lets >> you update the properties file without recompiling the template. >> > > But doesn't XmlTemplate.getCharacterData() insert an hard coded > string into the Java file? > parent.appendChild(parent.getOwnerDocument().createTextNode > (res.getString(idAttr.getNodeValue()))); > > -- > +--Matthew Buckett-----------------------------------------+ > | VLE Developer, Learning Technologies Group | > | Tel: +44 (0) 1865 283660 http://www.oucs.ox.ac.uk/ | > +------------Computing Services, University of Oxford------+ > > > ------------------------------------------------------- > This SF.Net email is sponsored by the 'Do More With Dual!' webinar > happening > July 14 at 8am PDT/11am EDT. We invite you to explore the latest in > dual > core and dual graphics technology at this free one hour event > hosted by HP, AMD, and NVIDIA. To register visit http://www.hp.com/ > go/dualwebinar > _______________________________________________ > Bodington-developers mailing list > Bod...@li... > https://lists.sourceforge.net/lists/listinfo/bodington-developers > |