diff options
author | Glen Mazza <gmazza@apache.org> | 2004-06-19 13:35:33 +0000 |
---|---|---|
committer | Glen Mazza <gmazza@apache.org> | 2004-06-19 13:35:33 +0000 |
commit | b7326926ad01239cbe89e64bf76d7ccc0cfb78cf (patch) | |
tree | 460a6260b9e6d6fad7a5d41ffecd6863793897af /src/java/org/apache/fop/fo/FONode.java | |
parent | 7689679503c48b854c84632c172a97bdf2dcd888 (diff) | |
download | xmlgraphics-fop-b7326926ad01239cbe89e64bf76d7ccc0cfb78cf.tar.gz xmlgraphics-fop-b7326926ad01239cbe89e64bf76d7ccc0cfb78cf.zip |
1.) FOInputHandler constructors switched from Document to FOUserAgent, Renderer added to FOTreeHandler interface.
2.) Apps.Document dropped.
3.) Validity checking added to fo.pagination.SinglePageMasterReference
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@197737 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java/org/apache/fop/fo/FONode.java')
-rw-r--r-- | src/java/org/apache/fop/fo/FONode.java | 31 |
1 files changed, 18 insertions, 13 deletions
diff --git a/src/java/org/apache/fop/fo/FONode.java b/src/java/org/apache/fop/fo/FONode.java index 15593de46..eb186a08b 100644 --- a/src/java/org/apache/fop/fo/FONode.java +++ b/src/java/org/apache/fop/fo/FONode.java @@ -20,13 +20,13 @@ package org.apache.fop.fo; // Java import java.util.ListIterator; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; // XML import org.xml.sax.Attributes; import org.xml.sax.Locator; -import org.apache.commons.logging.Log; - // FOP import org.apache.fop.apps.FOPException; import org.apache.fop.apps.FOUserAgent; @@ -34,6 +34,8 @@ import org.apache.fop.util.CharUtilities; import org.apache.fop.fo.extensions.ExtensionElementMapping; import org.apache.fop.fo.extensions.svg.SVGElementMapping; + + /** * base class for nodes in the XML tree * @@ -55,6 +57,9 @@ public abstract class FONode { /** Marks column number of this object in the input file **/ public int column; + /** Logger for fo-tree related messages **/ + private static Log log = LogFactory.getLog(FONode.class); + /** * Main constructor. * @param parent parent of this node @@ -76,11 +81,20 @@ public abstract class FONode { } /** + * Recursively goes up the FOTree hierarchy until the fo:root is found, + * which returns the parent FOInputHandler. + * @return the FOInputHandler object that is the parent of the FO Tree + */ + public FOInputHandler getFOInputHandler() { + return parent.getFOInputHandler(); + } + + /** * Returns the user agent for the node. * @return FOUserAgent */ public FOUserAgent getUserAgent() { - return getFOInputHandler().getDriver().getUserAgent(); + return getFOInputHandler().getUserAgent(); } /** @@ -88,7 +102,7 @@ public abstract class FONode { * @return the logger */ public Log getLogger() { - return getFOInputHandler().getDriver().getLogger(); + return log; } /** @@ -201,15 +215,6 @@ public abstract class FONode { } /** - * Recursively goes up the FOTree hierarchy until the fo:root is found, - * which returns the parent FOInputHandler. - * @return the FOInputHandler object that is the parent of the FO Tree - */ - public FOInputHandler getFOInputHandler() { - return parent.getFOInputHandler(); - } - - /** * This is a hook for an FOTreeVisitor subclass to be able to access * this object. * @param fotv the FOTreeVisitor subclass that can access this object. |