|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.ofbiz.webapp.view.ApacheFopWorker
public class ApacheFopWorker
Apache FOP worker class.
Nested Class Summary | |
---|---|
static class |
ApacheFopWorker.LocalResolver
Local URI resolver for the Transformer class. |
Field Summary | |
---|---|
protected static FopFactory |
fopFactory
|
static java.lang.String |
module
|
static java.lang.String |
tempFilePrefix
File name prefix used for temporary files. |
Constructor Summary | |
---|---|
ApacheFopWorker()
|
Method Summary | |
---|---|
static Fop |
createFopInstance(java.io.OutputStream out,
java.lang.String outputFormat)
Returns a new Fop instance. |
static java.io.File |
createTempFoXmlFile()
Returns a temporary File instance. |
static java.io.File |
createTempResultFile()
Returns a temporary File instance. |
static FopFactory |
getFactoryInstance()
Returns an instance of the FopFactory class. |
static void |
transform(java.io.File srcFile,
java.io.File destFile,
java.io.File stylesheetFile,
java.lang.String outputFormat)
Transform an xsl-fo file to the specified file format. |
static void |
transform(java.io.InputStream srcStream,
java.io.OutputStream destStream,
java.io.InputStream stylesheetStream,
java.lang.String outputFormat)
Transform an xsl-fo InputStream to the specified OutputStream format. |
static void |
transform(javax.xml.transform.stream.StreamSource src,
javax.xml.transform.stream.StreamSource stylesheet,
Fop fop)
Transform an xsl-fo StreamSource to the specified output format. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String module
public static final java.lang.String tempFilePrefix
org.ofbiz.webapp.view.ApacheFopWorker-
.
protected static FopFactory fopFactory
Constructor Detail |
---|
public ApacheFopWorker()
Method Detail |
---|
public static FopFactory getFactoryInstance()
public static void transform(java.io.File srcFile, java.io.File destFile, java.io.File stylesheetFile, java.lang.String outputFormat) throws java.io.IOException, FOPException
srcFile
- The xsl-fo File instancedestFile
- The target (result) File instancestylesheetFile
- Optional stylesheet File instanceoutputFormat
- Optional output format, defaults to "application/pdf"
java.io.IOException
FOPException
public static void transform(java.io.InputStream srcStream, java.io.OutputStream destStream, java.io.InputStream stylesheetStream, java.lang.String outputFormat) throws FOPException
srcStream
- The xsl-fo InputStream instancedestStream
- The target (result) OutputStream instancestylesheetStream
- Optional stylesheet InputStream instanceoutputFormat
- Optional output format, defaults to "application/pdf"
FOPException
public static void transform(javax.xml.transform.stream.StreamSource src, javax.xml.transform.stream.StreamSource stylesheet, Fop fop) throws FOPException
src
- The xsl-fo StreamSource instancestylesheet
- Optional stylesheet StreamSource instancefop
-
FOPException
public static Fop createFopInstance(java.io.OutputStream out, java.lang.String outputFormat) throws FOPException
out
- The target (result) OutputStream instanceoutputFormat
- Optional output format, defaults to "application/pdf"
FOPException
public static java.io.File createTempFoXmlFile() throws java.io.IOException
FOP performs transforms in memory, so if there is any chance FO output will be more than a few pages, it would be best to keep FO input in a temporary file.
java.io.IOException
public static java.io.File createTempResultFile() throws java.io.IOException
FOP performs transforms in memory, so if there is any chance FO output will be more than a few pages, it would be best to keep FO output in a temporary file.
java.io.IOException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |