xml editor

Supported platforms

Compatible with Windows7 & Mac OS X Snow Leopard

Ready for data server software
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

Re: [xsl] transforming multiple xml sources into a single stream


Subject: Re: [xsl] transforming multiple xml sources into a single stream
From: "J.Pietschmann" <j3322ptm@xxxxxxxx>
Date: Thu, 16 Oct 2003 23:02:17 +0200

Pramodh Peddi wrote:
I am using Java1.4.1's API for Transformation. I have 2 different xml
streams (not files on disk) in memory and have to use transformation to
merge them into a single xml stream. Is this possible?

Yes.


I know there is way to merge 2 xml files into a single if the files are on
the disk, but I am wondering if we can do this when streams are in memory.

There are several methods. The most geeky one is of course to write a custom URIResolver and use it with a custom URI scheme in order to pull in an in-memory stream via document(). There is sample code for this in the list archive, or have a look at the Cocoon project (http://cocoon.apache.org).

Less innovative methods include building two DOMs and merge them
(memory intensive), merge via a SAX filter or merging the streams
directly, perhaps using a custom FilterStream subclass (may be
brittle).

J.Pietschmann



XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list



Current Thread
Keywords
XML Editor | XML Author | WYSIWYG Editors | Schema Editor | XSD Documentation | XSL/XSLT Editor | XQuery | XML Databases | SVN Client
© 2002-2011 SyncRO Soft Ltd. All rights reserved. | Sitemap | Privacy Policy | This website was created & generated with <oXygen/>®XML Editor