Re: [xslt] Extension module initialization is called for every imported stylesheet
- From: "Oleg A. Paraschenko" <olpa xmlhack ru>
- To: veillard redhat com, The Gnome XSLT library mailing-list <xslt gnome org>
- Cc:
- Subject: Re: [xslt] Extension module initialization is called for every imported stylesheet
- Date: Wed, 3 May 2006 07:56:58 +0400
Hello,
On Tue, 2 May 2006 17:18:59 -0400
Daniel Veillard <veillard redhat com> wrote:
> On Tue, May 02, 2006 at 09:31:40PM +0200, Buchcik, Kasimier wrote:
> > Hi,
> >
> > Extension module initialization functions will be called
> > once for every imported stylesheet (plus the main stylesheet).
> > The initialization function is the "xsltStyleExtInitFunction"
> > argument of the xsltRegisterExtModuleFull() function.
> > Is this the intended design? I.e., is the initialization
> > expected to be called for *every* imported stylehsheet and not
> > only once for a whole stylesheet compilation episode?
As far as I remember, more precise behaviour is the following.
Initialization is expected for every (imported or main) stylesheet which
has the corresponding "extension-element-prefixes".
>
> It's probably an oversight, once per stylesheet should be sufficient.
Do you mean "once per the whole stylesheet"? I think it is not sufficient.
I have a chain of imported xslt-files that looks like:
-- [code]
<x:stylesheet extension-element-prefixes="myx" ...>
<myx:init>...</myx:init>
...
</x:stylesheet>
--- [/code]
When my xsltStyleExtInitFunction is activated, it looks for "myx:init" and
performs additional initialization for the corresponding xslt file. If the
function were called only once, I'd have problems to locate all "myx:init"
in all xslt files.
>
> Daniel
>
--
Oleg Parashchenko olpa@ http://xmlhack.ru/ XML news in Russian
http://uucode.com/blog/ Generative Programming, XML, TeX, Scheme
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]