File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

DOMParser problem

 
Sagar Rohankar
Ranch Hand
Posts: 2906
1
Java Spring Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi all

Actually i dont know where to put exactly a XML related question, so lastly i put it into this section

Her is my problem:
i want to put a XML files element name and its encloses text data as 'Key , Value ' pair in HashMap instance. I wrote a code but , not able to do exactly as above..

here is my try

list is my instance of HashMap class.


when i iterate thru map , i got following result :
[output]
=9679623159ec4a51a9
Key=s
ROOT=Request
[/output]

my xml file is :
[xml]
<Request>
<Key>9679623159ec4a51a9</Key>
</Request>
[/xml]

Thanks in advance
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Actually i dont know where to put exactly a XML related question, so lastly i put it into this section

We have an XML forum, so I'll move this over there.
 
Sagar Rohankar
Ranch Hand
Posts: 2906
1
Java Spring Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi all

i just solve the problem, it required a 15 minute break and sip of hot coffee !!

i just take temp string and stored a element value which i take from Node.ELEMENT case and in Node.TEXT , i put it with text value

 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic