The Artima Developer Community
Sponsored Link

Java Answers Forum
ANT task

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
kunal

Posts: 4
Nickname: kunal
Registered: Jul, 2003

ANT task Posted: Aug 18, 2003 1:56 AM
Reply to this message Reply
Advertisement
Hi,

I am trying to execute an anttask.I have defined it in build.xml using <taskdef> element.

In <taskdef> I have given four attributes,reuqired as input parameters to the java program implementing the task.

Foll. is the <taskdef>

<taskdef name="xmltask" classname="Mytask"/>
<xmltask filename="C:\\Anttask\\xpath\\contentMap.xml" query="/ContentMap/Content/Schema/Table[@ID='VKVMACK']/KeyValue[@ID='NAMA']" attributeid="ID" attrvalue="aaaa"/>

In the task I am parsing the given file using DOM.When I am trying to get the root element it is giving

doc = [#document: null]

But when I configure this task as java task in the build.xml
it does not give the null,instead it prints the xml.

<java classname="Mytask" fork="yes">
<classpath path="${classpath}"/>
<arg value="C:\\Anttask\\xpath\\contentMap.xml"/>
<arg value="/ContentMap/Content/Schema/Table[@ID='VKVMACK']/KeyValue[@ID='NAMA']"/&g t;
<arg value="ID"/>
<arg value="aaaa"/>
</java>


Can anybody please tell me what is going wrong while executing the task by <taskdef>

Bye,

Kunal

Topic: java programing Previous Topic   Next Topic Topic: where can i find source code for system explorer

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use