cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vadim Gritsenko" <vadim.gritse...@verizon.net>
Subject RE: ScriptGenerator problem
Date Tue, 16 Apr 2002 00:35:54 GMT
> From: William Brogden [mailto:wbrogden@bga.com]
> 
> > -----Original Message-----
> > From: Vadim Gritsenko [mailto:vadim.gritsenko@verizon.net]
> > Sent: Monday, April 15, 2002 2:30 PM
> > To: cocoon-users@xml.apache.org
> > Subject: RE: ScriptGenerator problem
> >
> >
> > > From: William Brogden [mailto:wbrogden@bga.com]
> > >
> > >
> > > I am attempting to add Python script processing capability to the
> > > ScriptGenerator using jython.
> > >
> > > I placed jython.jar in the cocoon/WEB-INF/lib directory
> > > Cocoon version is 2.0.1 dated 2/26/02
> > > Erased the work directory before starting
> > >
> > > Here is my modified "script" generator entry in sitemap.xmap:
> > >
> > > <map:generator name="script"
> > > src="org.apache.cocoon.generation.ScriptGenerator"
> > >     logger="sitemap.generator.script" label="content,data" >
> > >     <add-languages>
> > >       <language name="python"
> > src="org.python.util.PythonInterpreter">
> > >         <extension map:value="py"/>
> >
> > map:value is neither supported nor valid construct anymore. Try
this:
> >
> >   <extension>py</extension>
> >
> >
> > Vadim
> 
> Ah - that is the nomenclature that appears in the Javadocs for
> org.apache.cocoon.generation.ScriptGenerator so I used it.
> 
> On further fooling around I find that ScriptGenerator seems
> to come already configured for Python and you can access the
> docs/samples/scripts/hello.py file.
> 
> But where in the world does that configuration occur? Is it
> built in to BSF?

Kind of:

BSFManager.getLangFromFilename() does the trick.

Vadim

 
> WBB
> 


---------------------------------------------------------------------
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: <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail: <cocoon-users-help@xml.apache.org>


Mime
View raw message