RE: Possibility of converting from XML to PDF without the intermediate stage of FO format
Title: Possibility of converting from XML to PDF without the intermediate stage of FO format I have also noticed that doing the XML to FO to PDF in memory as opposed to writing to disk reduces time by about 80% in the samples that I tried. I was using iTEXT, XEP, FOP, RTF2FO etc. Below you say that a 56 page PDF from XML files takes about 2 minutes. That sounds really good - I was working with 2 pages and 2 XML files generating FO doing an XSLT transform to merge and coverting to PDF and that was taking me about 1.5 minutes on a 333MHZ machine. I was just curoius what the total sizes of the XML, the FOs and the PDF were. Did you concate the FOs? how did you get a single PDF (what tool)? steveb -Original Message-From: Jie Wang [mailto:[EMAIL PROTECTED]Sent: Tuesday, June 11, 2002 6:37 PMTo: '[EMAIL PROTECTED]'Subject: RE: Possibility of converting from XML to PDF without the intermediate stage of FO format The size of xml file is 330K. -Original Message-From: Buonincontri, Steve (CAP, MMF, ITSS) [mailto:[EMAIL PROTECTED]Sent: Tuesday, June 11, 2002 3:37 PMTo: [EMAIL PROTECTED]Subject: RE: Possibility of converting from XML to PDF without the intermediate stage of FO format Just curious - what are the sizes of the XML, FO and PDF files? -Original Message-From: Jie Wang [mailto:[EMAIL PROTECTED]Sent: Tuesday, June 11, 2002 5:31 PMTo: '[EMAIL PROTECTED]'Subject: Possibility of converting from XML to PDF without the intermediate stage of FO format How to decrease the responding time of converting from XML to PDF ? Currently it took me about 2 Mins to generate my 56 page PDF from XML files. Is that possible to convert from XML to PDF without the intermediate stage of FO format ? Thanks, Jie -Original Message- From: Oleg Tkachenko [mailto:[EMAIL PROTECTED]] Sent: Tuesday, June 04, 2002 11:47 AM To: [EMAIL PROTECTED] Subject: Re: FOP error with There are no chapter_title or sub formatting objects in xsl-fo, you have to transform it in xslt to fo objects, like rather than just copying them to the fo. [EMAIL PROTECTED] wrote: > Hi, > > I am attaching the test xsl,xml and the java files. The problem is that the description of any node could have tags and text mixed. If I use (with FOP), I get only > the text and when I use (without FOP embeded), I get the desired result, but with FOP I am getting 'error 10231' I have tried everything that I could think of and could not come up with the correct stylesheet. > I truly could use your help > I am anxiously waiting for a solution. > > Thank you so much in advance. > Norm > > --- ERROR - > ERROR 10231 [fop ] (): Unknown formatting object null^chapter_title > Exception in thread "main" org.apache.fop.apps.FOPException: java.lang.NullPoin > erException > at org.apache.fop.apps.Driver.render(Driver.java:486) > at test1.main(test1.java:102) > > test.xml -- > > > > > Testing Chapter 3 > > > > -- test.xsl --- > http://www.w3.org/1999/XSL/Transform" version="1.0" > xmlns:fo="http://www.w3.org/1999/XSL/Format"> > > http://www.w3.org/1999/XSL/Format"> > > > margin-top="10mm" margin-bottom="10mm" margin-left="20mm" margin-right="20mm"> > > margin-left="0mm" margin-right="0mm"/> > > > > > > > > > > > > > > > > > break-after="page"> > > > > > > --- test.java file just the main() > public static void main () { > > File xmlFile=new File("test.xml"); > File xslFile=new File("test.xsl"); > File pdfFile=new File("test.pdf");
RE: Possibility of converting from XML to PDF without the intermediate stage of FO format
Title: Possibility of converting from XML to PDF without the intermediate stage of FO format And the FO and PDF? -Original Message-From: Jie Wang [mailto:[EMAIL PROTECTED]Sent: Tuesday, June 11, 2002 6:37 PMTo: '[EMAIL PROTECTED]'Subject: RE: Possibility of converting from XML to PDF without the intermediate stage of FO format The size of xml file is 330K. -Original Message-From: Buonincontri, Steve (CAP, MMF, ITSS) [mailto:[EMAIL PROTECTED]Sent: Tuesday, June 11, 2002 3:37 PMTo: [EMAIL PROTECTED]Subject: RE: Possibility of converting from XML to PDF without the intermediate stage of FO format Just curious - what are the sizes of the XML, FO and PDF files? -Original Message-From: Jie Wang [mailto:[EMAIL PROTECTED]Sent: Tuesday, June 11, 2002 5:31 PMTo: '[EMAIL PROTECTED]'Subject: Possibility of converting from XML to PDF without the intermediate stage of FO format How to decrease the responding time of converting from XML to PDF ? Currently it took me about 2 Mins to generate my 56 page PDF from XML files. Is that possible to convert from XML to PDF without the intermediate stage of FO format ? Thanks, Jie -Original Message- From: Oleg Tkachenko [mailto:[EMAIL PROTECTED]] Sent: Tuesday, June 04, 2002 11:47 AM To: [EMAIL PROTECTED] Subject: Re: FOP error with There are no chapter_title or sub formatting objects in xsl-fo, you have to transform it in xslt to fo objects, like rather than just copying them to the fo. [EMAIL PROTECTED] wrote: > Hi, > > I am attaching the test xsl,xml and the java files. The problem is that the description of any node could have tags and text mixed. If I use (with FOP), I get only > the text and when I use (without FOP embeded), I get the desired result, but with FOP I am getting 'error 10231' I have tried everything that I could think of and could not come up with the correct stylesheet. > I truly could use your help > I am anxiously waiting for a solution. > > Thank you so much in advance. > Norm > > --- ERROR - > ERROR 10231 [fop ] (): Unknown formatting object null^chapter_title > Exception in thread "main" org.apache.fop.apps.FOPException: java.lang.NullPoin > erException > at org.apache.fop.apps.Driver.render(Driver.java:486) > at test1.main(test1.java:102) > > test.xml -- > > > > > Testing Chapter 3 > > > > -- test.xsl --- > http://www.w3.org/1999/XSL/Transform" version="1.0" > xmlns:fo="http://www.w3.org/1999/XSL/Format"> > > http://www.w3.org/1999/XSL/Format"> > > > margin-top="10mm" margin-bottom="10mm" margin-left="20mm" margin-right="20mm"> > > margin-left="0mm" margin-right="0mm"/> > > > > > > > > > > > > > > > > > break-after="page"> > > > > > > --- test.java file just the main() > public static void main () { > > File xmlFile=new File("test.xml"); > File xslFile=new File("test.xsl"); > File pdfFile=new File("test.pdf"); > > Logger log = null; > > if(log == null) { > Hierarchy hierarchy = Hierarchy.getDefaultHierarchy(); > log = hierarchy.getLoggerFor("fop"); > log.setPriority(Priority.WARN); > } > FileOutputStream OutFile = new FileOutputStream(pdfFile); > ByteArrayOutputStream out = new ByteArrayOutputStream(); > Driver driver=new Driver(); &g
RE: Possibility of converting from XML to PDF without the intermediate stage of FO format
Title: Possibility of converting from XML to PDF without the intermediate stage of FO format Just curious - what are the sizes of the XML, FO and PDF files? -Original Message-From: Jie Wang [mailto:[EMAIL PROTECTED]Sent: Tuesday, June 11, 2002 5:31 PMTo: '[EMAIL PROTECTED]'Subject: Possibility of converting from XML to PDF without the intermediate stage of FO format How to decrease the responding time of converting from XML to PDF ? Currently it took me about 2 Mins to generate my 56 page PDF from XML files. Is that possible to convert from XML to PDF without the intermediate stage of FO format ? Thanks, Jie -Original Message- From: Oleg Tkachenko [mailto:[EMAIL PROTECTED]] Sent: Tuesday, June 04, 2002 11:47 AM To: [EMAIL PROTECTED] Subject: Re: FOP error with There are no chapter_title or sub formatting objects in xsl-fo, you have to transform it in xslt to fo objects, like rather than just copying them to the fo. [EMAIL PROTECTED] wrote: > Hi, > > I am attaching the test xsl,xml and the java files. The problem is that the description of any node could have tags and text mixed. If I use (with FOP), I get only > the text and when I use (without FOP embeded), I get the desired result, but with FOP I am getting 'error 10231' I have tried everything that I could think of and could not come up with the correct stylesheet. > I truly could use your help > I am anxiously waiting for a solution. > > Thank you so much in advance. > Norm > > --- ERROR - > ERROR 10231 [fop ] (): Unknown formatting object null^chapter_title > Exception in thread "main" org.apache.fop.apps.FOPException: java.lang.NullPoin > erException > at org.apache.fop.apps.Driver.render(Driver.java:486) > at test1.main(test1.java:102) > > test.xml -- > > > > > Testing Chapter 3 > > > > -- test.xsl --- > http://www.w3.org/1999/XSL/Transform" version="1.0" > xmlns:fo="http://www.w3.org/1999/XSL/Format"> > > http://www.w3.org/1999/XSL/Format"> > > > margin-top="10mm" margin-bottom="10mm" margin-left="20mm" margin-right="20mm"> > > margin-left="0mm" margin-right="0mm"/> > > > > > > > > > > > > > > > > > break-after="page"> > > > > > > --- test.java file just the main() > public static void main () { > > File xmlFile=new File("test.xml"); > File xslFile=new File("test.xsl"); > File pdfFile=new File("test.pdf"); > > Logger log = null; > > if(log == null) { > Hierarchy hierarchy = Hierarchy.getDefaultHierarchy(); > log = hierarchy.getLoggerFor("fop"); > log.setPriority(Priority.WARN); > } > FileOutputStream OutFile = new FileOutputStream(pdfFile); > ByteArrayOutputStream out = new ByteArrayOutputStream(); > Driver driver=new Driver(); > > driver.setLogger(log); > driver.setRenderer(Driver.RENDER_PDF); > InputHandler ih=new XSLTInputHandler(xmlFile,xslFile); > XMLReader p=ih.getParser(); > driver.setOutputStream(OutFile); > driver.render(p, ih.getInputSource()); > OutFile.close(); > } > }//main > > > __ > Your favorite stores, helpful shopping tools and great gift ideas. Experience the convenience of buying online with [EMAIL PROTECTED] http://shopnow.netscape.com/ > > Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/ > -- Oleg Tkachenko Multiconn International, Israel