an XML file and extract values for the
attributes using ANT script
FYI. You could read the file into a property and use regular
expressions. Since it's XML the patterns would not be too difficult
Sent from my iPhone
On Jul 25, 2008, at 4:36 AM, Alpesh Vesuwala
<[EMAIL PROTECTED
SUPERB =)
I was trying,
/ :rules: XYZ/text()"/>
/ :rules: ABC/text()"/>
@{xyz} = @{abc}
Thanks a lot,
Alpesh
--
View this message in context:
http://www.nabble.com/How-to-read-an-XML-fil
Well, that's slightly different. The follwoing will illustrate what you
need..
@{xyz} = @{abc}
Brian
On Thu, July 31, 2008 10:21, Alpesh Vesuwala wrote:
>
> Hi,
>
> Thanks for your qui
Hi,
Thanks for your quick response.
The solution is fine but not working when my XML file looks like this:
123
456
987
654
147
258
Thanks and Regards,
Alpesh
You should be able to do that with a param to call. i.e. identify the node
you're interested in wit
You should be able to do that with a param to call. i.e. identify the node
you're interested in with:
and specify a param:
http://www.nabble.com/How-to-read-an-XML-file-and-extract-values-for-the-attributes-using-ANT-script-tp18648408p18749436.html
> Sent from the Ant - Users mailing list archi
Hey one more twist has come with my requirement.
the above solution of xmltask requires separate 'call' to loop through 'XYZ'
and 'ABC'
Resulting in, I have first all the values of XYZ and then for ABC. and I
want values for both together.
e.g.
abc
xyz
123
456
Thanks Brian,
It works as per what I expected. :drunk:
Thank you very much,
Alpesh
--
View this message in context:
http://www.nabble.com/How-to-read-an-XML-file-and-extract-values-for-the-attributes-using-ANT-script-tp18648408p18732640.html
Sent from the Ant - Users mailing list archive at Na
You can use and its function. e.g.
val = @{val}
and some additional XPath magic ('following-sibling' or similar) to get
the following XYZ node (not tried this, though! You may need an XPath
tutorial like http://www.zvon.org/xxl/XPathTutorial/General/examples.html
)
Brian
On We
Thank you all for your valuable inputs.
I tried 'xmltask' for my solution and it is working really well. :jumping:
I really appreciate your kind responses. =)
Please clarify one more doubt,
I may have multiple tags and they can be random.
For example,
abc
xyz
123
I remember you can't do this directly with Ant, but you have to use an
extension...
Look at: XMLTask (xmltask-v1.15.1.jar)
Anthony MÜLLER
-Original Message-
From: Alpesh Vesuwala [mailto:[EMAIL PROTECTED]
Sent: Friday, July 25, 2008 11:37 AM
To: user@ant.apache.org
Subject: How to re
FYI. You could read the file into a property and use regular
expressions. Since it's XML the patterns would not be too difficult
Sent from my iPhone
On Jul 25, 2008, at 4:36 AM, Alpesh Vesuwala
<[EMAIL PROTECTED]> wrote:
Hello Friends,
I have an XML file to read from it and extract valu
XMLTask can do this.
http://www.oopsconsultancy.com/software/xmltask/
will copy the values into the properties prop1/prop2
Brian
On Fri, July 25, 2008 10:36, Alpesh Vesuwala wrote:
>
> Hello Friends,
>
> I have an XML file to read from it and extract values of some attributes.
> These ext
-Original Message-
From: Alpesh Vesuwala [mailto:[EMAIL PROTECTED]
Sent: Friday, July 25, 2008 11:37 AM
To: user@ant.apache.org
Subject: How to read an XML file and extract values for the attributes
using ANT script
/*
I have an XML file to read from it and extract values of some
attr
13 matches
Mail list logo