Just to clarify,

1) <t:myComponent t:title="*literal:*Page ${pageNo} of ${pageCount}" />
worked but incorrectly prepended "literal:" to the result.

2) <t:myComponent t:title="Page ${pageNo} of ${pageCount}" /> fails
complaing that the string "Page..${..}.." wasn't a page property.

3) <t:myComponent t:title="Page ${pageNo} of ${pageCount}" />  works
correctly when the "t:title" parameter is specified as having "literal" as
the default prefix.

I would think that sounds like a bug, or is at least inconsistent.  I would
have thought case 1 and 3 should produce the same output.

Cheers
Andrew


On Dec 6, 2007 4:09 AM, jeffrey ai <[EMAIL PROTECTED]> wrote:

>
> It's hardly to say it's a bug.
> I guess T5 will assume you meant to use literal binding when you use a
> value
> with expansions, like "... ${val1} ... ${val2}".
> So "literal" prefix is only necessary for a simple value, like "abc".
>
> Cheers,
> Jeffrey Ai
>
>
> Andrew Pietsch wrote:
> >
> > Hi there,
> >
> > I'm new to T5 so the I hope this isn't just a user misunderstanding but
> > I'm
> > having troubles with the prefix "literal:"
> >
> > Page class:
> > public class MyComponent
> > {
> >    @Parameter
> >    private String title;
> > }
> >
> > A Template that uses MyComponent as follows:
> > <t:myComponent t:title="literal:Page ${pageNo} of ${pageCount}" />
> >
> > The resulting output is:
> > literal: Page 1 of 3
> >
> >
> > If I change the parameter to use "literal" as the default binding the
> > output
> > correctly omits the "literal:" prefix.
> >
> > Cheers
> > Andrew
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/T5%3A-Possible-Literal-Binding-bug-tf4947411.html#a14175989
> Sent from the Tapestry - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

Reply via email to