we use also property files for that, only they are out ot the tapestry cycle, and are used by a layer between the business layer and tapestry - this layer delivers (among others) models and names for localizeable domain objects. It seemed to us that this might be the better way to go also because such models (IPropertySelectionModel) can be kept singletons for quite a few (db) domains which do not change (like colors, monthes aso)

cheers,
Ron


Aslak Gronflaten wrote:
Hi,

I'm internationalizing a tap 4 site I'm working on, which is quite
easy using span key="" , message: prefix and .properties files.
However, I have a lot of drop-downs for selections like color,
country, days, etc. which in the database are simple lookup tables
containing an id and a name. That's not enough for localization, so I
could either expand the datamodel, or use the name field as a key in
the messages lookup. I've been pursuing the second solution, as these
tables are pretty static, at least between releases of the site.
I am in doubt, however, whether the IProperySelectionModels that I
implement to deliver this data should perform the translation (lookup
in messages), or whether I need to extend the components
(PropertySelection, Palette and MultiplePropertySelection) to make
them look up the translations and render them. That seems a little
complicated. However, doing it in the model gives me a problem, since
my business layer that delivers the models know nothing about the
message repository. I would need to pass a reference to a Message down
to the business layer in order to construct the models. But this again
complicates caching, serialization etc.
A third path I suppose is to introduce a translation interceptor in
between. But what is best practice (or just advice) for this kind of
thing?

Thanks,
   Aslak

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to