File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Concatenating XML Docs

 
Med Shabe
Ranch Hand
Posts: 84
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I need suggestions for concatenating XML documents.
Would it be wiser to save the streams to files and then concatenate the needed elements using SAX or just do it with DOM? Considering that the size of each doc. could get 50+K, and also XSL will be applied to the final doc.
Snippets would greatly be appreciated.
[ April 15, 2003: Message edited by: Med Shabe ]
 
Tina Desai
Ranch Hand
Posts: 365
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Youcan do what is called a two stage tranformation. Write one xsl to merge the two xml files and then to that xml file apply your final xsl.
Check the document() function for this.
Cheers!
Tina
 
Med Shabe
Ranch Hand
Posts: 84
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the pointer.
I checked the document() function and all the samples deal with merging physical files. Any way to merge docs in memory, without saving to file?
Thanks much.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic