ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ed.Moo...@Sun.COM
Subject accessing attribute values not in the containing target
Date Wed, 07 Nov 2001 23:02:39 GMT
I'm writing a task that needs to retrieve attribute values from nested
elements in targets other than the current one. However, my getter
methods for attributes on elements not in the current target always
return null.

Debugging indicates that while Ant calls the constructor for all
nested elements during parsing, it calls attribute setter methods only
for nested elements in the current target. All the others remain
uninitialized.  Scanning the code indicates that a task's
RuntimeConfigurable has the fields I need, but doesn't provide methods
to access them. (A public getChildren() would be nice.)

I'd be grateful to anyone who can point out what I'm doing wrong, or a
way to get Ant to do what I want. I'm using v1.4.

Ed Mooney             |Sun Microsystems, Inc.|Time flies like
XML Technology Center |UBUR02-201            |an arrow, but
Ed.Mooney@Sun.COM     |1 Network Drive       |fruit flies like
781-442-0459          |Burlington, MA  01803 |a banana. Groucho

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message