I'm still not entirely what you're decoding from and to; it sounds like something is fundamentally broken, but...
Remember that with OGNL you *can* call arbitrary methods, including static utility methods, from with the EL. So with either a static decoding class or (preferably) a service object in your action if you're iterating over a list you can call methods on items from that list. d. --- Paolo Beccari <[EMAIL PROTECTED]> wrote: > > > --- Dave Newton wrote: > > > > Why? > > > > I'll try to explain. The main problem is, that i > would not to expose a > single getter-method in the action for each property > I want to decode. I'm > searching for a more generic method. > I thought on some possibile solution, one was to > return, in each action, the > entire decode set (roughly speaking, a series of > tuples name-value-decode). > That way, I could handle it with <s:iterator and > <s:if tag each time I need > a decode. In addition, if the decoded value I'm > searching is the last in the > list, the list is entirely scrolled before finding > result. So I tend to > discard that. > > Maybe it is only a matter of wrong architectural > design: we are returning to > the views some objects mapped from the database > layer "as they are". It is > possible we need an additional level between, to > provide decoded values for > each property, but the temptation to use a scriplet > <%=Decode(name, value)%> > with a generic, singleton Decoder class is still > strong :). > > > > > I've never had to do that, but if I did, I'd be > most > > likely to do it in the action or, more likely, a > > service object in the action. > > > > d. > > > > Yes, I'd be most likely to do, too. But I have to > find a way to NOT write > hundreds of methods, one for each decode-set. > Well, I'll continue thinking on it, BTW thanks for > reply. > > P. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: > [EMAIL PROTECTED] > For additional commands, e-mail: > [EMAIL PROTECTED] > > ____________________________________________________________________________________ Get the free Yahoo! toolbar and rest assured with the added security of spyware protection. http://new.toolbar.yahoo.com/toolbar/features/norton/index.php --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]