On 8/22/07, Peter Reilly <[EMAIL PROTECTED]> wrote:
> Matt had added something to IH to allow Object to be returned
> from property evaluation, I linked this to tasks/types that
> say they understand Object by having a setX(Object) signature.
>
> With local properties and setX(Object) in place one can do nice
> things:
> for example:
> <target name="tasks" depends="init">
> <el:for param="target" items="${el:project.targets.values()}">
> <echo>TARGET "${el:target.name}"</echo>
> <el:for param="task" items="${el:target.tasks}">
> <echo> TASK ${el:task.namespace}:${el:task.tag}</echo>
> </el:for>
> </el:for>
> </target>
> Of course going throu the build build is not a useful thing
> to do, however, being about to access the attributes of
> objects and iterating over them would be useful.
Sure, that's a nice "working" example, but then these setX(Object)
setters are not usable with plain string attributes, no? So you must
rely on documentation to specify what kind of Object it accepts. And
you can only provide these objects programmtically (in a non-type safe
way) or via a specific PropertyHelper expression. How will
type-mismatches be reported? How to troubleshoot them?
And the param attrib of your example, what does it set? A Local property?
Reading build files using such constructs will be difficult I fear,
because how things are supposed to work is very fuzzy it seems to me.
--DD
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]