diff options
author | Glen Mazza <gmazza@apache.org> | 2004-06-17 04:46:08 +0000 |
---|---|---|
committer | Glen Mazza <gmazza@apache.org> | 2004-06-17 04:46:08 +0000 |
commit | d706d3413b2509f7f5ff9e1f127b1aa37f447624 (patch) | |
tree | c460fbc95d18e3dd1f3dfaa1d0acbff813c6acb6 | |
parent | 4e89f502c93d90df557cea370776c70cc649f988 (diff) | |
download | xmlgraphics-fop-d706d3413b2509f7f5ff9e1f127b1aa37f447624.tar.gz xmlgraphics-fop-d706d3413b2509f7f5ff9e1f127b1aa37f447624.zip |
No-constructor loader created for Area Tree.
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@197721 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r-- | src/java/org/apache/fop/apps/Driver.java | 2 | ||||
-rw-r--r-- | src/java/org/apache/fop/area/AreaTree.java | 18 | ||||
-rw-r--r-- | src/java/org/apache/fop/tools/AreaTreeBuilder.java | 2 |
3 files changed, 10 insertions, 12 deletions
diff --git a/src/java/org/apache/fop/apps/Driver.java b/src/java/org/apache/fop/apps/Driver.java index 95175958b..07478a7b7 100644 --- a/src/java/org/apache/fop/apps/Driver.java +++ b/src/java/org/apache/fop/apps/Driver.java @@ -490,7 +490,7 @@ public class Driver { "Renderer not set when using standard foInputHandler"); } foInputHandler = new FOTreeHandler(currentDocument, true); - currentDocument.areaTree = new AreaTree(currentDocument); + currentDocument.areaTree = new AreaTree(); currentDocument.atModel = new RenderPagesModel(renderer); //this.atModel = new CachedRenderPagesModel(renderer); currentDocument.areaTree.setTreeModel(currentDocument.atModel); diff --git a/src/java/org/apache/fop/area/AreaTree.java b/src/java/org/apache/fop/area/AreaTree.java index 35f72fa51..2c5d57b05 100644 --- a/src/java/org/apache/fop/area/AreaTree.java +++ b/src/java/org/apache/fop/area/AreaTree.java @@ -18,7 +18,6 @@ package org.apache.fop.area; -import org.apache.fop.apps.Document; import org.apache.fop.area.extensions.BookmarkData; import org.apache.fop.fo.extensions.Outline; import org.apache.fop.fo.extensions.Bookmarks; @@ -31,6 +30,10 @@ import java.util.Set; import java.util.HashSet; import java.util.Iterator; +// Commons-Logging +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; + /** * Area tree for formatting objects. * @@ -52,7 +55,6 @@ public class AreaTree { // allows for different models to deal with adding/rendering // in different situations private AreaTreeModel model; - private Document document; // hashmap of arraylists containing pages with id area private Map idLocations = new HashMap(); @@ -60,12 +62,12 @@ public class AreaTree { private Map resolve = new HashMap(); private List treeExtensions = new ArrayList(); + private static Log log = LogFactory.getLog(AreaTree.class); + /** * Constructor. - * @param document the apps.Document object controlling this AreaTree */ - public AreaTree (Document document) { - this.document = document; + public AreaTree () { } @@ -225,7 +227,7 @@ public class AreaTree { return; } - document.getDriver().getLogger().debug("adding bookmarks to area tree"); + log.debug("adding bookmarks to area tree"); BookmarkData data = new BookmarkData(); for (int count = 0; count < bookmarks.getOutlines().size(); count++) { Outline out = (Outline)(bookmarks.getOutlines()).get(count); @@ -254,8 +256,4 @@ public class AreaTree { return data; } - public Document getDocument() { - return document; - } - } diff --git a/src/java/org/apache/fop/tools/AreaTreeBuilder.java b/src/java/org/apache/fop/tools/AreaTreeBuilder.java index 109a28e59..71b36ecbf 100644 --- a/src/java/org/apache/fop/tools/AreaTreeBuilder.java +++ b/src/java/org/apache/fop/tools/AreaTreeBuilder.java @@ -271,7 +271,7 @@ class TreeLoader { Element root = null; root = doc.getDocumentElement(); - areaTree = new AreaTree(document); + areaTree = new AreaTree(); areaTree.setTreeModel(model); readAreaTree(root); |