You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lenya.apache.org by eg...@apache.org on 2005/01/26 11:06:21 UTC

svn commit: r126494 - /lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/cms/cocoon/transformation/LinkRewritingTransformer.java

Author: egli
Date: Wed Jan 26 02:06:19 2005
New Revision: 126494

URL: http://svn.apache.org/viewcvs?view=rev&rev=126494
Log:
Added getter/setter methods for ignoreAElement
Modified:
   lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/cms/cocoon/transformation/LinkRewritingTransformer.java

Modified: lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/cms/cocoon/transformation/LinkRewritingTransformer.java
Url: http://svn.apache.org/viewcvs/lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/cms/cocoon/transformation/LinkRewritingTransformer.java?view=diff&rev=126494&p1=lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/cms/cocoon/transformation/LinkRewritingTransformer.java&r1=126493&p2=lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/cms/cocoon/transformation/LinkRewritingTransformer.java&r2=126494
==============================================================================
--- lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/cms/cocoon/transformation/LinkRewritingTransformer.java	(original)
+++ lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/cms/cocoon/transformation/LinkRewritingTransformer.java	Wed Jan 26 02:06:19 2005
@@ -165,14 +165,14 @@
 
         if (getLogger().isDebugEnabled()) {
             getLogger().debug(this.indent + "<" + qname + "> (ignoreAElement = "
-                    + this.ignoreAElement + ")");
+                    + isIgnoreAElement() + ")");
             this.indent += "  ";
         }
 
         AttributesImpl newAttrs = null;
         if (lookingAtAElement(name)) {
 
-            this.ignoreAElement = false;
+            setIgnoreAElement(false);
 
             String href = attrs.getValue(ATTRIBUTE_HREF);
             if (href != null) {
@@ -228,7 +228,7 @@
                             if (targetDocument.exists()) {
                                 rewriteLink(newAttrs, targetDocument, anchor);
                             } else {
-                                this.ignoreAElement = true;
+                                setIgnoreAElement(true);
                             }
                         }
                     }
@@ -241,10 +241,10 @@
         }
 
         if (getLogger().isDebugEnabled()) {
-            getLogger().debug(this.indent + "ignoreAElement: " + this.ignoreAElement);
+            getLogger().debug(this.indent + "ignoreAElement: " + isIgnoreAElement());
         }
 
-        if (!(lookingAtAElement(name) && this.ignoreAElement)) {
+        if (!(lookingAtAElement(name) && isIgnoreAElement())) {
             if (newAttrs != null) {
                 attrs = newAttrs;
             }
@@ -318,8 +318,8 @@
             this.indent = this.indent.substring(2);
             getLogger().debug(this.indent + "</" + qname + ">");
         }
-        if (lookingAtAElement(name) && this.ignoreAElement) {
-            this.ignoreAElement = false;
+        if (lookingAtAElement(name) && isIgnoreAElement()) {
+            setIgnoreAElement(false);
         } else {
             if (getLogger().isDebugEnabled()) {
                 getLogger().debug(this.indent + "</" + qname + "> sent");
@@ -353,5 +353,17 @@
      */
     public void recycle() {
         this.ignoreAElement = false;
+    }
+    /**
+     * @return Returns the ignoreAElement.
+     */
+    protected boolean isIgnoreAElement() {
+        return ignoreAElement;
+    }
+    /**
+     * @param ignoreAElement The ignoreAElement to set.
+     */
+    protected void setIgnoreAElement(boolean ignoreAElement) {
+        this.ignoreAElement = ignoreAElement;
     }
 }

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@lenya.apache.org
For additional commands, e-mail: commits-help@lenya.apache.org