webwork/src/main/webwork/view/taglib ActionTag.java,1.20,1.21 BeanTag.java,1.9,1.10 ElseIfTag.java,1.8,1.9 ElseTag.java,1.7,1.8 I18nTag.java,1.9,1.10 IfTag.java,1.9,1.10 PushTag.java,1.1,1.2

[email protected] Sun, 19 Jun 2005 16:46:05 -0700
Newsgroups gmane.comp.java.open-symphony.cvs
Message-ID <[email protected]>
Update of /cvsroot/opensymphony/webwork/src/main/webwork/view/taglib
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14894/src/main/webwork/view/taglib

Modified Files:
	ActionTag.java BeanTag.java ElseIfTag.java ElseTag.java 
	I18nTag.java IfTag.java PushTag.java 
Log Message:
Fixed more vs caching


Index: ActionTag.java
===================================================================
RCS file: /cvsroot/opensymphony/webwork/src/main/webwork/view/taglib/ActionTag.java,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -d -r1.20 -r1.21
--- ActionTag.java	12 Jun 2004 22:47:03 -0000	1.20
+++ ActionTag.java	19 Jun 2005 23:45:59 -0000	1.21
@@ -73,6 +73,7 @@
     public int doEndTag() throws JspException {
         gd.finish();
         gd.finalizeContext();
+        super.doEndTag();
         return EVAL_PAGE;
     }
 }

Index: BeanTag.java
===================================================================
RCS file: /cvsroot/opensymphony/webwork/src/main/webwork/view/taglib/BeanTag.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- BeanTag.java	17 Jan 2005 07:28:12 -0000	1.9
+++ BeanTag.java	19 Jun 2005 23:46:00 -0000	1.10
@@ -84,6 +84,7 @@
    public int doEndTag() throws JspException
    {
       getStack().popValue();
+      super.doEndTag();
       return EVAL_PAGE;
    }
 

Index: ElseIfTag.java
===================================================================
RCS file: /cvsroot/opensymphony/webwork/src/main/webwork/view/taglib/ElseIfTag.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- ElseIfTag.java	30 Sep 2002 16:17:51 -0000	1.8
+++ ElseIfTag.java	19 Jun 2005 23:46:00 -0000	1.9
@@ -1,77 +1,78 @@
-/*
- * WebWork, Web Application Framework
- *
- * Distributable under Apache license.
- * See terms of license at opensource.org
- */
-package webwork.view.taglib;
-
-import javax.servlet.jsp.JspException;
-import javax.servlet.jsp.tagext.Tag;
-
-/**
- *
- * @author Maurice C. Parker ([email protected])
- * @version $Revision$
- */
-public class ElseIfTag
-      extends WebWorkTagSupport {
-   // Attributes ----------------------------------------------------
-   protected String test;
-   protected boolean answer;
-
-   // Public --------------------------------------------------------
-   /**
-    * Set the test condition.
-    *
-    * @param   str
-    */
-   public void setTest(String str) {
-      test = str;
-   }
-
-   // BodyTag implementation ---------------------------------------
-   public int doStartTag() throws JspException {
-      Boolean ifResult = getId() == null ?
-            (Boolean) pageContext.getAttribute(IfTag.ANSWER) :
-            (Boolean) pageContext.getAttribute(getId());
-
-      if (ifResult == null || ifResult.booleanValue() == true) {
-         return SKIP_BODY;
-      }
+/*
+ * WebWork, Web Application Framework
+ *
+ * Distributable under Apache license.
+ * See terms of license at opensource.org
+ */
+package webwork.view.taglib;
+
+import javax.servlet.jsp.JspException;
+import javax.servlet.jsp.tagext.Tag;
+
+/**
+ *
+ * @author Maurice C. Parker ([email protected])
+ * @version $Revision$
+ */
+public class ElseIfTag
+      extends WebWorkTagSupport {
+   // Attributes ----------------------------------------------------
+   protected String test;
+   protected boolean answer;
+
+   // Public --------------------------------------------------------
+   /**
+    * Set the test condition.
+    *
+    * @param   str
+    */
+   public void setTest(String str) {
+      test = str;
+   }
+
+   // BodyTag implementation ---------------------------------------
+   public int doStartTag() throws JspException {
+      Boolean ifResult = getId() == null ?
+            (Boolean) pageContext.getAttribute(IfTag.ANSWER) :
+            (Boolean) pageContext.getAttribute(getId());
+
+      if (ifResult == null || ifResult.booleanValue() == true) {
+         return SKIP_BODY;
+      }
       answer = getStack().test(test);
-      // Make comparison
-      if (answer) {
-         return EVAL_BODY_INCLUDE;
-      } else {
-         return SKIP_BODY;
-      }
-   }
-
-   public int doEndTag() throws JspException {
-      if (answer) {
-         if (getId() != null)
-            pageContext.setAttribute(getId(), new Boolean(answer));
-
-         pageContext.setAttribute(IfTag.ANSWER, new Boolean(answer));
-      }
-      answer=false;
-      return EVAL_PAGE;
-   }
-
-   public void setParent(Tag t) {
-      super.setParent(t);
-
-      // Reset
-      //test = null;
-      //answer = false;
-   }
-
-   public void release()
-   {
-      setId(null);
-      super.release();
-   }
+      // Make comparison
+      if (answer) {
+         return EVAL_BODY_INCLUDE;
+      } else {
+         return SKIP_BODY;
+      }
+   }
+
+   public int doEndTag() throws JspException {
+      if (answer) {
+         if (getId() != null)
+            pageContext.setAttribute(getId(), new Boolean(answer));
+
+         pageContext.setAttribute(IfTag.ANSWER, new Boolean(answer));
+      }
+      answer=false;
+      super.doEndTag();
+      return EVAL_PAGE;
+   }
+
+   public void setParent(Tag t) {
+      super.setParent(t);
+
+      // Reset
+      //test = null;
+      //answer = false;
+   }
+
+   public void release()
+   {
+      setId(null);
+      super.release();
+   }
 }
 
 

Index: ElseTag.java
===================================================================
RCS file: /cvsroot/opensymphony/webwork/src/main/webwork/view/taglib/ElseTag.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- ElseTag.java	30 Sep 2002 16:17:51 -0000	1.7
+++ ElseTag.java	19 Jun 2005 23:46:00 -0000	1.8
@@ -1,47 +1,46 @@
-/*
- * WebWork, Web Application Framework
- *
- * Distributable under Apache license.
- * See terms of license at opensource.org
- */
-package webwork.view.taglib;
-
-import javax.servlet.jsp.JspException;
-import javax.servlet.jsp.tagext.Tag;
-import javax.servlet.jsp.tagext.TagSupport;
-
-/**
- *
- * @author Maurice C. Parker ([email protected])
- * @version $Revision$
- */
-public class ElseTag
-      extends TagSupport {
-   // BodyTag implementation ---------------------------------------
-   public int doStartTag() throws JspException {
-      Boolean ifResult = getId() == null ?
-            (Boolean) pageContext.getAttribute(IfTag.ANSWER) :
-            (Boolean) pageContext.getAttribute(getId());
-
-      pageContext.removeAttribute(IfTag.ANSWER);
-
-      if (ifResult == null || ifResult.booleanValue() == true) {
-         return SKIP_BODY;
-      } else {
-         return EVAL_BODY_INCLUDE;
-      }
-   }
-
-   public int doEndTag() throws JspException
-   {
-      return super.doEndTag();
-   }
-
-   public void release()
-   {
-      setId(null);
-      super.release();
-   }
+/*
+ * WebWork, Web Application Framework
+ *
+ * Distributable under Apache license.
+ * See terms of license at opensource.org
+ */
+package webwork.view.taglib;
+
+import javax.servlet.jsp.JspException;
+import javax.servlet.jsp.tagext.TagSupport;
+
+/**
+ *
+ * @author Maurice C. Parker ([email protected])
+ * @version $Revision$
+ */
+public class ElseTag
+      extends TagSupport {
+   // BodyTag implementation ---------------------------------------
+   public int doStartTag() throws JspException {
+      Boolean ifResult = getId() == null ?
+            (Boolean) pageContext.getAttribute(IfTag.ANSWER) :
+            (Boolean) pageContext.getAttribute(getId());
+
+      pageContext.removeAttribute(IfTag.ANSWER);
+
+      if (ifResult == null || ifResult.booleanValue() == true) {
+         return SKIP_BODY;
+      } else {
+         return EVAL_BODY_INCLUDE;
+      }
+   }
+
+   public int doEndTag() throws JspException
+   {
+      return super.doEndTag();
+   }
+
+   public void release()
+   {
+      setId(null);
+      super.release();
+   }
 }
 
 

Index: I18nTag.java
===================================================================
RCS file: /cvsroot/opensymphony/webwork/src/main/webwork/view/taglib/I18nTag.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- I18nTag.java	17 Jun 2003 15:48:34 -0000	1.9
+++ I18nTag.java	19 Jun 2005 23:46:00 -0000	1.10
@@ -78,6 +78,7 @@
    public int doEndTag() throws JspException
    {
       getStack().popValue();
+      super.doEndTag();
       return EVAL_PAGE;
    }
 

Index: IfTag.java
===================================================================
RCS file: /cvsroot/opensymphony/webwork/src/main/webwork/view/taglib/IfTag.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- IfTag.java	30 Sep 2002 16:17:51 -0000	1.9
+++ IfTag.java	19 Jun 2005 23:46:00 -0000	1.10
@@ -1,66 +1,68 @@
-/*
- * WebWork, Web Application Framework
- *
- * Distributable under Apache license.
- * See terms of license at opensource.org
- */
-package webwork.view.taglib;
-
-import javax.servlet.jsp.JspException;
-import javax.servlet.jsp.tagext.Tag;
-
-/**
- *
- * @author Maurice C. Parker ([email protected])
- * @version $Revision$
- */
-public class IfTag
-      extends WebWorkTagSupport {
-   // Attributes ----------------------------------------------------
-   public final static String ANSWER = "webwork.if.answer";
-
-   protected String test;
-   protected boolean answer;
-
-   // Public --------------------------------------------------------
-
-   /**
-    * Set the test condition.
-    *
-    * @param   str
-    */
-   public void setTest(String str) {
-      test = str;
-   }
-
-   // BodyTag implementation ---------------------------------------
-   public int doStartTag() throws JspException {
+/*
+ * WebWork, Web Application Framework
+ *
+ * Distributable under Apache license.
+ * See terms of license at opensource.org
+ */
+package webwork.view.taglib;
+
+import javax.servlet.jsp.JspException;
+import javax.servlet.jsp.tagext.Tag;
+
+/**
+ *
+ * @author Maurice C. Parker ([email protected])
+ * @version $Revision$
+ */
+public class IfTag
+      extends WebWorkTagSupport {
+   // Attributes ----------------------------------------------------
+   public final static String ANSWER = "webwork.if.answer";
+
+   protected String test;
+   protected boolean answer;
+
+   // Public --------------------------------------------------------
+
+   /**
+    * Set the test condition.
+    *
+    * @param   str
+    */
+   public void setTest(String str) {
+      test = str;
+   }
+
+   // BodyTag implementation ---------------------------------------
+   public int doStartTag() throws JspException {
       answer = getStack().test(test);
-      // Make comparison
-      if (answer) {
-         return EVAL_BODY_INCLUDE;
-      } else {
-         return SKIP_BODY;
-      }
-   }
-
-   public int doEndTag() throws JspException {
-      if (getId() != null) {
-         pageContext.setAttribute(getId(), new Boolean(answer));
-      }
-      pageContext.setAttribute(IfTag.ANSWER, new Boolean(answer));
-      answer=false;
-      return EVAL_PAGE;
-   }
-
-   public void setParent(Tag t) {
-      super.setParent(t);
   }
-
-   public void release()
-   {
-      setId(null);
-      super.release();
-   }
+      // Make comparison
+      if (answer) {
+         return EVAL_BODY_INCLUDE;
+      } else {
+         return SKIP_BODY;
+      }
+   }
+
+   public int doEndTag() throws JspException {
+      if (getId() != null) {
+         pageContext.setAttribute(getId(), new Boolean(answer));
+      }
+      pageContext.setAttribute(IfTag.ANSWER, new Boolean(answer));
+      answer=false;
+      super.doEndTag();
+      return EVAL_PAGE;
+   }
+
+   public void setParent(Tag t) {
+      super.setParent(t);
+   }
+
+   public void release()
+   {
+      setId(null);
+      super.release();
+   }
 }
 
 

Index: PushTag.java
===================================================================
RCS file: /cvsroot/opensymphony/webwork/src/main/webwork/view/taglib/PushTag.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- PushTag.java	6 Nov 2003 14:28:44 -0000	1.1
+++ PushTag.java	19 Jun 2005 23:46:01 -0000	1.2
@@ -39,6 +39,7 @@
    {
    	// Pop the value from the stack
       getStack().popValue();
+      super.doEndTag();
       return EVAL_PAGE;
    }
 }



-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click