You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Carlos Araya <ca...@cvc.edu> on 2002/02/17 09:01:08 UTC

Re: I may be confused - can I put Saxon into cocoon, or run Xerces at the command line?

Stephen:

If you want to make sure that it's Xerces and not a difference between
Xerces and the Xalan parser that comes with cocoon (The two parsers use
different extensions and some of those may conflict with cocoon), ran Saxon
with Xerces as the parser using a command like this:

java com.icl.saxon.StyleSheet -x org.apache.xerces.parsers.SAXParser <name
of the file> <name of the stylesheet>

That will report any error with the XML


HTH

Carlos

On 02/16/02 22:21, "Stephen Clarke" <an...@longusername.worldonline.co.uk>
wrote:

> Hi,
> I've been having fun running xml and xsl through the saxon parser.
> Everything works fine, and recently I've discovered cocoon and so I've been
> using cocoon to serve my xml/xsl dynamically. But just today I discovered
> for the first time an xslt that works fine with saxon in batch, but won't
> parse with Xerces in Cocoon. I think Cocoon uses Xerces, right?
> 
> So I've been thinking, the thing to do is to figure out how to run xerces at
> the command line in order to test my code that way and check error messages.
> 
> Then it occured to me, maybe there is some way I can get my Saxon parser
> *into* cocoon so that the whole thing will be seamless. Now above all, I
> don't want to get into anything time consuming here. I can only handle so
> many levels of detail at once. But how difficult would it be to get Saxon
> into cocoon, or would it be better to run Xerces from the command line.
> 
> Or am I just barking up the wrong tree altogether and does this email
> display errant confusion from which I need to be rescued before there is to
> be any hope of progress?
> 
> {:-(
> 
> --
> Stephen Clarke
> 
> PS. I'm on Win2k.
> 
> 
> ---------------------------------------------------------------------
> Please check that your question has not already been answered in the
> FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
> 
> To unsubscribe, e-mail: <co...@xml.apache.org>
> For additional commands, e-mail: <co...@xml.apache.org>
> 

-- 
Carlos E. Araya
---+ WebCT Administrator/Trainer
 P | California Virtual Campus
 - | C/O De Anza College
 G | 21250 Stevens Creek Blvd
---+ Cupertino, CA 95014

email               carlos@cvc.edu
web                 http://www.cvc1.org/ (work)
                    http://www.silverwolf-net.net (personal)
phone               408 257 0420 (work)
PGP Fingerprint:    E629 5DFD 7EAE 4995 E9D7  3D2F 5A9F 0CE7 DFE7 1756

"Come to think of it, there already are a million monkeys at a
million typewriters, and usenet is _NOTHING_ like Shakespeare." -
Blair Houghton.


---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>


Re: I may be confused - can I put Saxon into cocoon, or runXerces at the command line?

Posted by Carlos Araya <ca...@cvc.edu>.
On 02/17/02 10:04, "Stephen Clarke" <an...@longusername.worldonline.co.uk>
wrote:

> Hi Carlos,
> 
> Thanks for taking the trouble to reply. I did try what you suggested, but I
> regret things didn't go quite according to plan. Here's what happened.
> 
> First of all I got a ClassDefNotFound on the saxon StyleSheet, so I
> downloaded the full Saxon ( i was using instant, ehem ) and put saxon.jar in
> my classpath. Now i am getting a TransformerException on
> org.apache.xerces.parsers.SAXParser.
My apologies. The command I sent was for the command line version of Saxon.
I don't use it on servlets, prefering to run Saxon by hand

> 
> In any case, I'm not sure I want to use Xerces. If cocoon comes with Xalan
> then maybe I should use that one. I have since discovered that Saxon uses
> the AElfred parser ( whatever that is ). So I have an xsl that works fine
> with saxon but throws a big bluey in cocoon. Maybe my qestion ought to be
> 'How can i run at the command line whatever cocoon is doing internally, so
> that I can check for errors'
Saxon and Xalan implement different extensions differently. You can run both
Saxon and Xalan from the command line, but be aware from the start that they
will not work exactly the same with a given piece of XSLT stylesheets.

> 
> With that in mind, and just for kicks, I tried changing 'xerces' to 'xalan'
> in your instrunctions. No cigar.
See answer above.

> 
> If someone happens to know what I need to know, please pass that important
> information my way. I'd be very grateful.
Sorry I couldn't be anymore help
Carlos

> --
> Best,
> Stephen
> 
> ----- Original Message -----

>> java com.icl.saxon.StyleSheet -x org.apache.xerces.parsers.SAXParser <name
>> of the file> <name of the stylesheet>
-- 
Carlos E. Araya
---+ WebCT Administrator/Trainer
 P | California Virtual Campus
 - | C/O De Anza College
 G | 21250 Stevens Creek Blvd
---+ Cupertino, CA 95014

email               carlos@cvc.edu
web                 http://www.cvc1.org/ (work)
                    http://www.silverwolf-net.net (personal)
phone               408 257 0420 (work)
PGP Fingerprint:    E629 5DFD 7EAE 4995 E9D7  3D2F 5A9F 0CE7 DFE7 1756


"Do not meddle in the affairs of dragons....for you are crunchy and  taste
good with ketchup and mayonnaise.."




---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>


Re: I may be confused - can I put Saxon into cocoon, or runXerces at the command line?

Posted by Stephen Clarke <an...@longusername.worldonline.co.uk>.
Hi Carlos,

Thanks for taking the trouble to reply. I did try what you suggested, but I
regret things didn't go quite according to plan. Here's what happened.

First of all I got a ClassDefNotFound on the saxon StyleSheet, so I
downloaded the full Saxon ( i was using instant, ehem ) and put saxon.jar in
my classpath. Now i am getting a TransformerException on
org.apache.xerces.parsers.SAXParser.

In any case, I'm not sure I want to use Xerces. If cocoon comes with Xalan
then maybe I should use that one. I have since discovered that Saxon uses
the AElfred parser ( whatever that is ). So I have an xsl that works fine
with saxon but throws a big bluey in cocoon. Maybe my qestion ought to be
'How can i run at the command line whatever cocoon is doing internally, so
that I can check for errors'

With that in mind, and just for kicks, I tried changing 'xerces' to 'xalan'
in your instrunctions. No cigar.

If someone happens to know what I need to know, please pass that important
information my way. I'd be very grateful.
--
Best,
Stephen

----- Original Message -----
From: "Carlos Araya" <ca...@cvc.edu>
To: <co...@xml.apache.org>
Sent: Sunday, February 17, 2002 8:01 AM
Subject: Re: I may be confused - can I put Saxon into cocoon, or runXerces
at the command line?


> Stephen:
>
> If you want to make sure that it's Xerces and not a difference between
> Xerces and the Xalan parser that comes with cocoon (The two parsers use
> different extensions and some of those may conflict with cocoon), ran
Saxon
> with Xerces as the parser using a command like this:
>
> java com.icl.saxon.StyleSheet -x org.apache.xerces.parsers.SAXParser <name
> of the file> <name of the stylesheet>
>
> That will report any error with the XML
>
>
> HTH
>
> Carlos
>
> On 02/16/02 22:21, "Stephen Clarke" <an...@longusername.worldonline.co.uk>
> wrote:
>
> > Hi,
> > I've been having fun running xml and xsl through the saxon parser.
> > Everything works fine, and recently I've discovered cocoon and so I've
been
> > using cocoon to serve my xml/xsl dynamically. But just today I
discovered
> > for the first time an xslt that works fine with saxon in batch, but
won't
> > parse with Xerces in Cocoon. I think Cocoon uses Xerces, right?
> >
> > So I've been thinking, the thing to do is to figure out how to run
xerces at
> > the command line in order to test my code that way and check error
messages.
> >
> > Then it occured to me, maybe there is some way I can get my Saxon parser
> > *into* cocoon so that the whole thing will be seamless. Now above all, I
> > don't want to get into anything time consuming here. I can only handle
so
> > many levels of detail at once. But how difficult would it be to get
Saxon
> > into cocoon, or would it be better to run Xerces from the command line.
> >
> > Or am I just barking up the wrong tree altogether and does this email
> > display errant confusion from which I need to be rescued before there is
to
> > be any hope of progress?
> >
> > {:-(
> >
> > --
> > Stephen Clarke
> >
> > PS. I'm on Win2k.
> >
> >
> > ---------------------------------------------------------------------
> > Please check that your question has not already been answered in the
> > FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
> >
> > To unsubscribe, e-mail: <co...@xml.apache.org>
> > For additional commands, e-mail: <co...@xml.apache.org>
> >
>
> --
> Carlos E. Araya
> ---+ WebCT Administrator/Trainer
>  P | California Virtual Campus
>  - | C/O De Anza College
>  G | 21250 Stevens Creek Blvd
> ---+ Cupertino, CA 95014
>
> email               carlos@cvc.edu
> web                 http://www.cvc1.org/ (work)
>                     http://www.silverwolf-net.net (personal)
> phone               408 257 0420 (work)
> PGP Fingerprint:    E629 5DFD 7EAE 4995 E9D7  3D2F 5A9F 0CE7 DFE7 1756
>
> "Come to think of it, there already are a million monkeys at a
> million typewriters, and usenet is _NOTHING_ like Shakespeare." -
> Blair Houghton.
>
>
> ---------------------------------------------------------------------
> Please check that your question has not already been answered in the
> FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
>
> To unsubscribe, e-mail: <co...@xml.apache.org>
> For additional commands, e-mail: <co...@xml.apache.org>
>


---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>