ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rebhan, Gilbert" <Gilbert.Reb...@huk-coburg.de>
Subject RE: RegExp help needed!
Date Mon, 07 Dec 2009 14:38:28 GMT
 

-----Original Message-----
From: Jowie [mailto:joe.nash@mac.com] 
Sent: Monday, December 07, 2009 3:28 PM
To: user@ant.apache.org
Subject: RE: RegExp help needed!

/*
[...]

 Games\Main\ant\update_offline.xml:77: required attribute
img not set

But... If I do

		<xmltask source="${local.path}GetAllQuestions.xml">
			<call path="//*">
				<!-- target="getMedia" buffer="abc"-->
				
				<actions>
				    <echo>img = @{img}</echo>
				</actions>
			</call>
		</xmltask>

I get back:

     [echo] img = /brain_games_main/Image.ashx?ID=647
     [echo] img = /brain_games_main/Image.ashx?ID=647
     [echo] img = /brain_games_main/Image.ashx?ID=647
     [echo] img = /brain_games_main/Image.ashx?ID=647
     [echo] img = /brain_games_main/Image.ashx?ID=647
     [echo] img = /brain_games_main/Image.ashx?ID=647

etc....
*/


when using <actions> ... </actions> instead
of <all path="..." target="...">  you have to write =

<xmltask source="xpathtest.xml">
  <call path="//*">
    <param name="img" path="//@Media"/>
     <actions>
       <echo>img = @{img}</echo>
      </actions>
   </call>
</xmltask>

to match all Media attributes.



Gilbert


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


Mime
View raw message