You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by Arron Bates <ar...@keyboardmonkey.com> on 2001/11/06 01:01:52 UTC
Hold the Phone!... Nesting Tags (including form items)
Worthy developers (especially those with commit abilities :),
Attached is something that I think that a lot of people would find
useful, and... too easy to integrate.
From what I know (open to debate), there's no way to properly nest
beans within beans and be able to use them properly without
masses of duplicated Html, unrelenting amounts of bean properties or
whatever. Certainly can't nest through more than one iterator tag.
Consider the following bean composition...
monkeyTeamAlpha.monkeyWorkers[1].productivity.pickedBunches[1].bananaList[0].flavour
The example attached has everything needed to manage that structure
(change values on beans on all levels) on only one JSP page in a very
elegant fashion.
I've been in one side of this and out the other. Created my own indexed
tags (before the nightly build version) and another nested-indexed (tree
structure) tag
system before I realised this, and it was too easy. You guys had already
coded it for me (at least the PropertyUtils half). I could get it
working in terms of viewing using nothing but struts, but the issue was
that it couldn't set against the nested properties as the tags weren't
concerned with writing out nested properties. Hence these tags.
The running example (if you want to confirm it's cool before wasting
your time)...
http://www.keyboardmonkey.com/MonkeyStruts.jsp
There's so many was to build on it to bring in even more niceties...
plenty of ideas, but that's the step after this one... adoption of the idea.
It's already past the "absolutely handy" phase and in production on code
I have here. It's saved days of development and made the way for
solutions that would have been impossible... and allowed some really
nice bean composition. Truly has.
The attached war file is ready for plonking into tomcat with the
exception that struts.jar isn't in it's lib directory (figured you guys
would handle that).
Take a look around... I look forward to your comments.
Arron Bates.
(theKM*)
* keyboard's here, the monkey is in the mail
Re: Hold the Phone!... Nesting Tags (including form items)
Posted by Arron Bates <ar...@keyboardmonkey.com>.
OK... Service provider doesn't like running webapps.... just run it local.
You'll have more fun anyways ;)
Arron.
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>