From 969ceeeb4c8c9c5bf45285792e70bba4fb62374a Mon Sep 17 00:00:00 2001 From: Glen Mazza Date: Sun, 4 Jul 2004 04:50:54 +0000 Subject: [PATCH] Removed isMarker() method in favor of getName() (may eventually switch to an ID system for element names for better performance.) git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@197751 13f79535-47bb-0310-9956-ffa450edef68 --- src/java/org/apache/fop/fo/FONode.java | 11 ----------- src/java/org/apache/fop/fo/FObj.java | 2 +- src/java/org/apache/fop/fo/flow/Marker.java | 7 ------- 3 files changed, 1 insertion(+), 19 deletions(-) diff --git a/src/java/org/apache/fop/fo/FONode.java b/src/java/org/apache/fop/fo/FONode.java index eb186a08b..a542706a5 100644 --- a/src/java/org/apache/fop/fo/FONode.java +++ b/src/java/org/apache/fop/fo/FONode.java @@ -203,17 +203,6 @@ public abstract class FONode { return new OneCharIterator(CharUtilities.CODE_EOT); } - /** - * This is a quick check to see if it is a marker. - * This is needed since there is no other quick way of checking - * for a marker and not adding to the child list. - * - * @return true if this is a marker - */ - protected boolean isMarker() { - return false; - } - /** * This is a hook for an FOTreeVisitor subclass to be able to access * this object. diff --git a/src/java/org/apache/fop/fo/FObj.java b/src/java/org/apache/fop/fo/FObj.java index ec4864fac..64a681326 100644 --- a/src/java/org/apache/fop/fo/FObj.java +++ b/src/java/org/apache/fop/fo/FObj.java @@ -256,7 +256,7 @@ public class FObj extends FONode implements Constants { * @param child the child node to add */ protected void addChild(FONode child) { - if (containsMarkers() && child.isMarker()) { + if (containsMarkers() && "fo:marker".equals(child.getName())) { addMarker((Marker)child); } else { if (children == null) { diff --git a/src/java/org/apache/fop/fo/flow/Marker.java b/src/java/org/apache/fop/fo/flow/Marker.java index 215557bfc..cbc6a55fd 100644 --- a/src/java/org/apache/fop/fo/flow/Marker.java +++ b/src/java/org/apache/fop/fo/flow/Marker.java @@ -54,13 +54,6 @@ public class Marker extends FObjMixed { this.propertyList.get(PR_MARKER_CLASS_NAME).getString(); } - /** - * @see org.apache.fop.fo.FONode#isMarker() - */ - protected boolean isMarker() { - return true; - } - /** * Get the marker class name for this marker. * -- 2.39.5