You can use a recursive function to change context to each document and then
return the results of each keyed access.
David
-----Original Message-----
From: saxon-help-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx
[mailto:saxon-help-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx]On
Behalf Of Willink, Ed
Sent: 12 January 2004 10:39
To: 'saxon-help-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx'
Subject: RE: [saxon] Chaining of transformations in Saxon?
Hi
> > >
> > > Main disadvantage is that keys cannot be used on subsequent
> > > passes, since keys are defined with respect to the read not
> > > recreate context.
> > >
> > I'm not quite sure what you mean by this comment. Keys can
> be used in
> > any phase of the transformation. You always have to be careful when
> > using the key() function to get the context right (key()
> > finds nodes in
> > the same document as the context node), but apart from
> that, there are
> > no limitations. Certainly you *can* use keys on temporary trees.
>
> Interesting.
Unfortunately, this doesn't always work in practice.
If I want to use @xmi:id as a key, and execute in multiple passes,
then I have a separate root for each pass, one for the input and
one for each variable holding additional intermediates.
Since the @xmi:id may need resolution across more than one 'document' root,
I cannot rely on a key to resolve an @xmi:idref.
[Incidentally, is there an elegant way to intercept the generic node
construction/copy process to auto-create an @xmi:id]
Regards
Ed Willink
------------------------------------------------------------------------
E.D.Willink, Email:
mailto:EdWillink-7KbaBNvhQFM@xxxxxxxxxxxxxxxx
Thales Research and Technology (UK) Ltd, Tel: +44 118 923 8278 (direct)
Worton Drive, or +44 118 986 8601 (ext 8278)
Worton Grange Business Park, Fax: +44 118 923 8399
Reading, RG2 0SB
ENGLAND http://www.computing.surrey.ac.uk/personal/pg/E.Willink
------------------------------------------------------------------------
-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
_______________________________________________
saxon-help mailing list
saxon-help-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/saxon-help
---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.557 / Virus Database: 349 - Release Date: 30/12/2003
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.557 / Virus Database: 349 - Release Date: 30/12/2003
-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
|
|