ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matt Benson <gudnabr...@yahoo.com>
Subject Re: Executing for all elements in an xml document...
Date Fri, 27 Aug 2004 21:49:53 GMT
For each file listed in the XML structure you want to
perform a series of operations:  store the remote file
locally using <get>, then do some arbitrary
processing, correct?  Without knowing much about XSLT,
you might use that or some home-brewed means (custom
Task) of converting the XML to a list like you are
already using.  You might experiment with making the
conversion using regular expressions, perhaps with
AC's <propertyregexp>.  It might take a true regexp
guru, but I think it may be possible.

-Matt

--- "Alan J. Zall" <alan@xcipio.com> wrote:

> 	We have a nightly pull procedure that connects to a
> remote server
> via https with basic authentication and performs a
> <get> to retrieve a one
> file at a time. The owners of the remote server have
> set up the server so
> that when I submit to the root directory an xml
> representation of the
> directory is returned. 
> 	My challenge is to perform a series of tasks on
> each of the files
> listed. Currently I have a list of the files
> hard-coded in a property that I
> iterate through. I would like to iterate based on
> the elements in the xml
> document. Is this possible?
> 
> Here is the modified result of the directory listing
> 
> <files>
> 	<file id="1">file1.DAT.zip</file>
> 	<file id="2">file2.DAT.zip</file>
> </files>
> 
> Here is the hard coded property file that I use:
> 
> agenciesList= file1.DAT.zip, file2.DAT.zip
> 
> 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> user-unsubscribe@ant.apache.org
> For additional commands, e-mail:
> user-help@ant.apache.org
> 
> 



		
_______________________________
Do you Yahoo!?
Win 1 of 4,000 free domain names from Yahoo! Enter now.
http://promotions.yahoo.com/goldrush

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message