Well in JSF Convertors is a part of validation logic and they are provide a
way to notify application that conversion was unsuccessful. In Tapestry I
see Translator is almost the same as Converter in JSF. Using Translator I
can notify my application that conversion was unsuccessful. I've been
looking at
http://tapestry.apache.org/tapestry5/apidocs/org/apache/tapestry/ValueEncoder.htmland
I didn't find any way in ValueEncoder how I can throw any conversion
exception. Maybe someone can provide some more examples how ValueEncoder can
be used?

On Sun, Mar 30, 2008 at 2:08 PM, Howard Lewis Ship <[EMAIL PROTECTED]> wrote:

> Actually, this looks closer to the ValueEncoder interface.  For
> example, the tapestry-hibernate module includes ValueEncoders to
> convert between Hibernate entities and their primary keys (as
> strings).  The ValueEncoderSource interface is useful here, since it
> allows components that need a ValueEncoder to obtain one based on the
> type of property bound to their value parameter, automatically.
>
> On Sun, Mar 30, 2008 at 1:14 PM, Yura Tkachenko
> <[EMAIL PROTECTED]> wrote:
> > Thank you.
> >
> >
> >
> >  On 3/30/08, Thiago HP <[EMAIL PROTECTED]> wrote:
> >  >
> >  > On 3/30/08, Yura Tkachenko <[EMAIL PROTECTED]> wrote:
> >  > >  Does Tapestry 5 have something like converters?
> >  >
> >  > Yes. Take a look at the Translator interfade
> >  > (
> >  >
> http://tapestry.apache.org/tapestry5/apidocs/org/apache/tapestry/Translator.html
> >  > )
> >  > and the translate parameter of the TextField component
> >  > (
> >  >
> http://tapestry.apache.org/tapestry5/tapestry-core/ref/org/apache/tapestry/corelib/components/TextField.html
> >  > )
> >  > and other related ones.
> >  >
> >  > --
> >  > Thiago
> >  >
> >  > ---------------------------------------------------------------------
> >  > To unsubscribe, e-mail: [EMAIL PROTECTED]
> >  > For additional commands, e-mail: [EMAIL PROTECTED]
> >  >
> >  >
> >
>
>
>
> --
> Howard M. Lewis Ship
>
> Creator Apache Tapestry and Apache HiveMind
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

Reply via email to