Hi Arnauld,

I'm new to Xalan, so you already helped me with mentioning 
XSLTEngineImpl. However I find it quite difficult to get
something working based on the API docs. Can you please
give me some pointers where to look for additional info
or code samples?

Thanks a lot,
Achim

-----Original Message-----
From: Arnaud Malguy [mailto:[EMAIL PROTECTED]]
Sent: Thursday, August 23, 2001 9:28 AM
To: [EMAIL PROTECTED]
Subject: Re: XalanTransfomer with DOM input


Thank you for all of these answers.
I understand that if a functionnality work in one way
it's not top priority to make it working in another way.

Trasnformation with DOM input work with XSLTEngineImpl and
it's enough for me.

Thanks again

I'm agree with you when you say

[EMAIL PROTECTED] wrote:

> Hi Achim,
>
> It's not been taken out of Xalan-C++, it's been taken out of
> XalanTransformer.  The reason is that we re-wrote the tranformer to allow
> for pre-parsing of source trees.  Now, a transformer instance can accept a
> pre-parsed tree.  If you don't give it one, it builds one and then
> transforms it.  Trying to keep the old way of doing things along with the
> new way of doing things was too difficult to do with the limited resources
> and fairly aggressive schedule we had to work with.
>
> In general, we're trying to move away from directly transforming the
Xerces
> DOM because it's very difficult to do it properly and achieve good
> performance.  Trying to get DOM transformations to work within the new
> XalanTransformer will be fairly difficult to do, so I couldn't finish it
> for 1.2.
>
> Dave
>
>
>                       Achim �hlenschl�ger
>                       <achim.oehlenschlae         To:
[EMAIL PROTECTED]
>                       [EMAIL PROTECTED]>                 cc:      (bcc: David N
Bertoni/CAM/Lotus)
>                       Sent by:                    Subject: Re:
XalanTransfomer with DOM input
>                       achim.oehlenschlaeg
>                       [EMAIL PROTECTED]
>
>
>                       08/22/2001 03:25 PM
>                       Please respond to
>                       xalan-dev
>
>
>
> Hi David,
>
> I fear I'm confused by this answer.
> I was using DOM input based on the example
> "Working  with DOM input and output" from the "Basic Usage Patterns"
> with Xalan C++ 1.1 (NT 4.0) sucessfully.
> After I've updated to 1.2 today, I'm getting the same error as Arnaud.
> Has the DOM support been taken out of 1.2? Why?
>
> Thanks,
> Achim
>
> [EMAIL PROTECTED] wrote:
> >
> > Hi Arnaud,
> >
> > We don't currently support DOM input for the transformer.  We'll
probably
> > look at adding support for something like that in the future, but we
just
> > didn't have time to get all of the features in.  It's also not clear
that
> > it's even possible to do, given the way the transfomer works.
> >
> > For the time being, you'll need to stick to the internal APIs to do this
> > sort of thing, and unless you're actually modifying the DOM between the
> > time you parse it and transform it, you should just let the transformer
> > parse the file.
> >
> > Dave
> >
> >
> >                       Arnaud Malguy
> >                       <Arnaud.Malguy@x         To:      xalan-dev
> <[EMAIL PROTECTED]>
> >                       ps-pro.com>              cc:      (bcc: David N
> Bertoni/CAM/Lotus)
> >                                                Subject: XalanTransfomer
> with DOM input
> >                       08/22/2001 07:31
> >                       AM
> >                       Please respond
> >                       to xalan-dev
> >
> >
> >
> > Hello,
> >
> > I use Xalan C++ 1.2 and i'm trying to implement a sequence of
> > transformation with DOM intermediate result.
> > For this, i need to use XalanDocument as input of
> > XalanTransfomer::transform method.
> > It seems to not work in my complete code then i create a basic sample
> which
> > don't work too.
> >
> > I got the following error :
> >     Fatal Error at (file , line 0, column 0): An exception occured!
> > Type:RuntimeException, Message:The primary document entity could not be
> > opened. Id={null}
> >
> > Could someone help me to correct the following code ?
> >
> >   XMLPlatformUtils::Initialize();
> >   XalanTransformer::initialize();
> >
> >   XercesDOMSupport domSupport;
> >   XercesParserLiaison parserLiaison(domSupport);
> >   XalanTransformer xalanTransformer;
> >
> >   XSLTInputSource input_source("test_in.xml");
> >   XSLTResultTarget output_result("test_out.xml");
> >   XSLTInputSource xslt_source("test.xslt");
> >
> >   DOMParser  theParser;
> >   // You MUST instruct the Xerces DOMParser NOT to create a
> DOM_XMLDecNode
> >   // in the DOM to represent the XML declaration. See
> > &quot;Limitations&quot; below.
> >   theParser.setToCreateXMLDeclTypeNode(false);
> >   theParser.parse("test_in.xml");
> >   const DOM_Document theDOM = theParser.getDocument();
> >
> >   XalanDocument* theDoc = parserLiaison.createDocument(theDOM);
> >
> >   XSLTInputSource input_dom_source(theDoc);
> >
> > // WORK
> >    xalanTransformer.transform(input_source, xslt_source, output_result);
> >
> > // Don't WORK
> >    xalanTransformer.transform(input_dom_source, xslt_source,
> > output_result);
> >
> > XalanTransformer::terminate();
> > XMLPlatformUtils::Terminate();
> >
> > Thanks a lot.
> >
> > Arnaud Malguy

Reply via email to