On jeu., 2009-10-29 at 09:22 +0100, Antonio Petrelli wrote:
> 2009/10/28 Nathan Bubna <[email protected]>:
> > One question, would it make sense to also add a:
> >
> > public String toLocalizedPattern(String format) {
> >     return toLocalizedPattern(format, getLocale()
> > }
> >
> > for completeness?  Or is that redundant?
> 
> IMHO this method would be useful too, as long as "getLocale" returns
> the currently-selected locale, IOW the client's locale.

That's the server locale by default elsewhere in such localized methods
(or, if present, the one defined in tools.xml). For consistency, I'd
rather keep it the same here.

Plus, the client locale should be explicitly handled, IMHO. If you
localize formats, I guess you also localize templates, you can maybe
have one date tool per handled language... and I think of several other
use cases where such a method would be useful as is, but still with the
server/tools.xml locale.


  Claude

> Antonio
> 
> ---------------------------------------------------------------------
> 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