You missed the discussion; I started with something close to your
solution, but then tried the current solution. I liked it more, so
did the other developers who were interested in this.
Outside of Eclipse formatting, what does the extra typing gain you?
Basically, the Java compiler does a little more text parsing, rather
than the runtime annotation code. I think the existing approach
("source=mySource") is closer to the HTML approach, which I prefer
(over the XML <binding> element).
Thanks for being a guinea pig!
On 7/7/05, Denis Souza <[EMAIL PROTECTED]> wrote:
>
>
>
> Hello Howard,
>
>
>
> Sorry to send this e-mail directly to you, but I didn't know where else to
> send it and I thought maybe the tapestry user list wouldn't be appropriate.
>
>
>
> Just recently I upgraded to Tapestry 4 and so I'm just now starting to get
> the feel of it. So I started using Tapestry Annotations (I'm a big fan of
> annotations) and I noticed that declaring components in pages with
> annotations is a bit strange, more specifically in regard to the bindings. I
> have seen some talking about it on the user list but I only realized what it
> really looked like when I saw it on my code. It just doesn't look right,
> Eclipse doesn't format it properly and it's not as easy to read. So if I may
> make a suggestion I was thinking it could be changed to something more like
> what is being used in EJB 3 development.
>
>
>
> It would look something like this:
>
>
>
> @Component(type = "Foreach")
>
> @Bindings({
>
> @Binding(name = "source", value = "mySource"),
>
> @Binding(name = "value", value = "myValue")
>
> })
>
> public abstract IComponent getMyForeach();
>
>
>
> instead of
>
>
>
> @Component(type = "Foreach", bindings = {"source=mySource",
> "value=myValue"})
>
> public abstract IComponent getMyForeach();
>
>
>
> It would look a bit cleaner and easier to read since Eclipse (and probably
> many other IDEs) would color and format each element appropriately and it
> would be closer in resemblance to the original xml format (in which you
> usually place one binding per line).
>
>
>
> Anyway, it's just a suggestion. I'm loving Tapestry and hope this suggestion
> can be some help in improving it. Thank you for all your hard work in this
> project.
>
>
>
> Cheers,
>
> Denis Souza
>
>
--
Howard M. Lewis Ship
Independent J2EE / Open-Source Java Consultant
Creator, Jakarta Tapestry
Creator, Jakarta HiveMind
Professional Tapestry training, mentoring, support
and project work. http://howardlewisship.com
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]