|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.foray.core.FOrayDocument
public class FOrayDocument
This class manages the process of parsing an input FO document and creating an FOTree.
Constructor Summary | |
---|---|
FOrayDocument(FOraySession session,
Document domDocument)
Constructor for processing a DOM Document containing an FO document. |
|
FOrayDocument(FOraySession session,
InputSource inputSource,
XMLReader parser)
Constructor for processing a SAX InputSource containing an FO document. |
|
FOrayDocument(FOraySession session,
Transformer jaxpTransformer,
Source jaxpSource)
Constructor for processing a semantic XML document using a JAXP Transformer. |
|
FOrayDocument(FOraySession session,
URL xmlInput,
URL xsltInput)
Constructor for JAXP processing, using supplied URLs to the xml and xslt input. |
Method Summary | |
---|---|
void |
cleanup(FOrayTarget target)
A hook for clients to call, allowing the document to clean up after itself. |
void |
dumpError(Exception exception)
Dumps an error to the logger. |
org.axsl.area.AreaTreeFactory |
getAreaTreeFactory()
Returns the AreaTreeFactory for this document. |
URL |
getBaseURL()
Required by FOTreeControl interface. |
ContentHandler |
getContentHandler()
Returns the tree builder (a SAX ContentHandler). |
org.axsl.font.FontConsumer |
getFontConsumer()
Returns the FontConsumer for this document. |
org.axsl.font.FontServer |
getFontServer()
Returns the FontServer. |
org.axsl.fo.FoTree |
getFOTreeBuilder()
Returns the FOTree for this document. |
org.axsl.graphic.GraphicServer |
getGraphicServer()
Returns the GraphicServer for this document. |
SAXResult |
getJAXPResult()
Returns the JAXP SAXResult (which encapsulates a SAX ContentHandler). |
org.axsl.layout.LayoutFactory |
getLayoutFactory()
Returns the LayoutFactory for this document. |
org.apache.commons.logging.Log |
getLogger()
Returns the logger. |
String |
getParserClassName()
Returns the name of the SAX parser class to use. |
SessionConfig |
getSessionConfig()
Returns the SessionConfig for this document. |
org.axsl.speech.SpeechServer |
getSpeechServer()
Returns the SpeechServer for this document. |
org.axsl.text.TextServer |
getTextServer()
Returns the TextServer for this document. |
void |
process()
Process the target. |
void |
processTarget(FOrayTarget target)
Process a given target by building the formatting object tree from the input. |
protected void |
registerTarget(FOrayTarget target)
Registers a FOrayTarget instance that this FOrayDocument should process. |
void |
run()
Runs the formatting and renderering process using the previously set inputsource and outputstream. |
void |
setTarget(FOrayTarget target)
Sets the target of this document. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FOrayDocument(FOraySession session, InputSource inputSource, XMLReader parser) throws FOrayException
session
- The parent FOraySession.inputSource
- A SAX InputSource which encapsulated an FO document,
that is, a document which is already in the XSL-FO namespace.parser
- A SAX parser. If null is passed, a default parser will be
provided.
FOrayException
- If "null" parser is passed and there is an error
creating one.public FOrayDocument(FOraySession session, Document domDocument) throws FOrayException
session
- The parent FOraySession.domDocument
- A DOM Document.
FOrayException
- For errors instantiating the document.public FOrayDocument(FOraySession session, Transformer jaxpTransformer, Source jaxpSource) throws FOrayException
session
- The parent FOraySession.jaxpTransformer
- The JAXP Transformer.jaxpSource
- The JAXP source.
FOrayException
- For errors instantiating the document.public FOrayDocument(FOraySession session, URL xmlInput, URL xsltInput) throws FOrayException
session
- The parent FOraySession.xmlInput
- The semantic XML input file to be processed.xsltInput
- The stylesheet to be processed.
FOrayException
- For errors instantiating the document.Method Detail |
---|
protected void registerTarget(FOrayTarget target)
target
- The FOrayTarget instance that should be processed.public ContentHandler getContentHandler()
public SAXResult getJAXPResult()
getContentHandler()
for the use-case.
public void setTarget(FOrayTarget target) throws FOrayException
target
- The child target.
FOrayException
- If the child target is not a child of this
document.public void process() throws FOrayException
FOrayException
- For errors during processing.public void processTarget(FOrayTarget target) throws FOrayException
target
- The target to be processed.
FOrayException
- For errors during processing.public void cleanup(FOrayTarget target)
target
- The target for which cleanup is needed.public void dumpError(Exception exception)
exception
- The exception that should be logged.public void run() throws IOException, FOrayException
IOException
- For I/O errors.
FOrayException
- For errors during processing.public org.apache.commons.logging.Log getLogger()
public org.axsl.font.FontServer getFontServer()
public String getParserClassName()
public URL getBaseURL()
public org.axsl.font.FontConsumer getFontConsumer()
public org.axsl.speech.SpeechServer getSpeechServer()
public org.axsl.text.TextServer getTextServer()
public org.axsl.graphic.GraphicServer getGraphicServer()
public SessionConfig getSessionConfig()
public org.axsl.fo.FoTree getFOTreeBuilder()
public org.axsl.area.AreaTreeFactory getAreaTreeFactory()
public org.axsl.layout.LayoutFactory getLayoutFactory()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |