cocoon-docs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache Wiki <wikidi...@apache.org>
Subject [Cocoon Wiki] Update of "AntennahouseSerializer" by MichaelWirz
Date Thu, 15 Dec 2005 10:44:23 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Cocoon Wiki" for change notification.

The following page has been changed by MichaelWirz:
http://wiki.apache.org/cocoon/AntennahouseSerializer

------------------------------------------------------------------------------
- Describe AntennahouseSerializer here.
+ PDF creation out of a cocoon pipline is a powerful and easy way to convert your html pages
into printable form. Standard cocoon embeds fop using the FOPSerializer. When speed comes
into account one might be interested in alternatives to fop. There are differnet commercial
xml-fo-renderers available. XEP comes with a cocoon serializer, Antennahouse Formatter does
not.
  
+ In the scenario (cocoon 1.8) I am currently working with we use Antennahouse by writing
documents to harddisc, calling the commandline script and loading the pdf from harddisc.
+ 
+ While migrating to cocoon 2.1 I rendered this scheme to the serializer-notation, i.e. streaming
the xml into the serializer and a pdf out of it. I did not get any JAVA-API or the like
+ for Antennahouse so the Serializer relies on a valid Antennahouse installation and the shell-script.
+ The given solution will work with any serialization process that is able to get its input
from stdin and stream its output to stdout.
+ 
+ You can use it like this:
+ 
+ Serializer definition (the shell command is given as cmd-tag inside the defintion):
+ 
+ ||<map:serializer logger="sitemap.serializer.antennahouse2pdf" mime-type="application/pdf"
name="antennahouse2pdf" src="de.abs.efonds24.sitemapElements.AntennaHouseSerializer">
+ ||  <cmd>/bin/bash /usr/XSLFormatterV3/run.sh -extlevel 3 -pea</cmd>
+ ||</map:serializer> 
+ 
+ Serializer usage (well known std pipeline):
+ 
+ ||<map:match pattern="pdffile.pdf">
+ ||  <map:generate type="file" src="source-xml-fo.xml"/>
+ ||  <map:transform type="xslt" src="stylesheet.xsl"/>
+ ||  <map:serialize type="antennahouse2pdf"/>
+ ||</map:match> 
+ 
+ 
+ This example does not include any licensed code from the Antennahouse Inc. but you will
need a valid license to test or use the Serializer.
+ 
+ I hope to hear from you if you like the idea, how you like the code and whether it works
for you or not.
+ Concerning speed we have to take into account that with this shell script based version,
parsing the xml-fo is necessary since no sax stream but the actual xml byte stream has to
be piped into the serialization process. Also there are buffers involved.
+ 
+ 
+ 
+ 

Mime
View raw message