Subject: RE: Portability function-available tips
From: "Michael Kay" <mhk@xxxxxxxxx>
Date: Fri, 9 Jan 2004 14:45:48 -0000
|
> > Two other suggestions for how to tackle this:
> >
> > (a) put the processor-dependent code in an external XML
> > entity, and use an EntityResolver to bring in the right
> > version of the external entity at stylesheet compile-time.
> >
> > (b) write a processor-dependent stylesheet overlay that
> > imports the main logic of the stylesheet and overrides the
> > processor-specific parts (for example, the global variable
> > "foo" in your example below). Use this overlay as the
> > nominated stylesheet for your transformation.
>
> Thanks Mike, but the some of the constraints on this project
> are that exactly the sames set of stylesheets should work
> unchanged with both Msxml 4 and Saxon - otherwise I would
> have used option B.
Well, with case A you could argue that the *stylesheets* are identical
in the two cases, the only difference is in the environment...
Michael Kay
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|