The following patch includes an API update from the JSP 2.0 specification.

jsr152/src/share/javax/servlet/jsp/tagext/SimpleTag.java:
    - Clarified javadocs for setJspContext()

jsr152/src/share/javax/servlet/jsp/tagext/SimpleTagSupport.java:
    - Clarified javadocs for setJspContext()

jsr152/src/share/javax/servlet/jsp/tagext/TagInfo.java:
    - Corrected error in constructor javadoc for JSP 1.1 TLD

jsr152/src/share/javax/servlet/jsp/tagext/JspFragment.java:
    - Changed to an abstract class
    - Added getJspContext() method

---
Mark Roth, Java Software
JSP 2.0 Co-Specification Lead
Sun Microsystems, Inc.
Index: jsr152/src/share/javax/servlet/jsp/tagext/JspFragment.java
===================================================================
RCS file: 
/home/cvspublic/jakarta-servletapi-5/jsr152/src/share/javax/servlet/jsp/tagext/JspFragment.java,v
retrieving revision 1.5
diff -u -r1.5 JspFragment.java
--- jsr152/src/share/javax/servlet/jsp/tagext/JspFragment.java  18 Dec 2002 18:35:37 
-0000      1.5
+++ jsr152/src/share/javax/servlet/jsp/tagext/JspFragment.java  8 Aug 2003 19:37:38 
-0000
@@ -66,7 +66,7 @@
  * The definition of the JSP fragment must only contain template 
  * text and JSP action elements.  In other words, it must not contain
  * scriptlets or scriptlet expressions.  At translation time, the 
- * container generates an implementation of the JspFragment interface
+ * container generates an implementation of the JspFragment abstract class
  * capable of executing the defined fragment.
  * <p>
  * A tag handler can invoke the fragment zero or more times, or 
@@ -85,7 +85,7 @@
  *
  * @since 2.0
  */
-public interface JspFragment {
+public abstract class JspFragment {
 
     /**
      * Executes the fragment and directs all output to the given Writer,
@@ -104,7 +104,14 @@
      * @throws java.io.IOException If there was an error writing to the 
      *     stream.
      */
-    public void invoke( java.io.Writer out )
+    public abstract void invoke( java.io.Writer out )
         throws javax.servlet.jsp.JspException, java.io.IOException;
+
+    /**
+     * Returns the JspContext that is bound to this JspFragment.
+     *
+     * @return The JspContext used by this fragment at invocation time.
+     */
+    public JspContext getJspContext();
 
 }
Index: jsr152/src/share/javax/servlet/jsp/tagext/SimpleTag.java
===================================================================
RCS file: 
/home/cvspublic/jakarta-servletapi-5/jsr152/src/share/javax/servlet/jsp/tagext/SimpleTag.java,v
retrieving revision 1.7
diff -u -r1.7 SimpleTag.java
--- jsr152/src/share/javax/servlet/jsp/tagext/SimpleTag.java    12 May 2003 16:52:10 
-0000      1.7
+++ jsr152/src/share/javax/servlet/jsp/tagext/SimpleTag.java    8 Aug 2003 19:37:38 
-0000
@@ -153,8 +153,9 @@
     public JspTag getParent();
     
     /**
-     * Stores the provided JSP context in the protected 
-     * jspContext field.
+     * Called by the container to provide this tag handler with
+     * the <code>JspContext</code> for this invocation.
+     * An implementation should save this value.
      * 
      * @param pc the page context for this invocation
      * @see Tag#setPageContext
Index: jsr152/src/share/javax/servlet/jsp/tagext/SimpleTagSupport.java
===================================================================
RCS file: 
/home/cvspublic/jakarta-servletapi-5/jsr152/src/share/javax/servlet/jsp/tagext/SimpleTagSupport.java,v
retrieving revision 1.8
diff -u -r1.8 SimpleTagSupport.java
--- jsr152/src/share/javax/servlet/jsp/tagext/SimpleTagSupport.java     16 May 2003 
02:39:00 -0000      1.8
+++ jsr152/src/share/javax/servlet/jsp/tagext/SimpleTagSupport.java     8 Aug 2003 
19:37:38 -0000
@@ -131,8 +131,9 @@
     }
     
     /**
-     * Stores the provided JSP context in the protected 
-     * jspContext field.
+     * Stores the provided JSP context in the private jspContext field.
+     * Subclasses can access the <code>JspContext</code> via 
+     * <code>getJspContext()</code>.
      * 
      * @param pc the page context for this invocation
      * @see SimpleTag#setJspContext
Index: jsr152/src/share/javax/servlet/jsp/tagext/TagInfo.java
===================================================================
RCS file: 
/home/cvspublic/jakarta-servletapi-5/jsr152/src/share/javax/servlet/jsp/tagext/TagInfo.java,v
retrieving revision 1.6
diff -u -r1.6 TagInfo.java
--- jsr152/src/share/javax/servlet/jsp/tagext/TagInfo.java      31 Mar 2003 17:52:26 
-0000      1.6
+++ jsr152/src/share/javax/servlet/jsp/tagext/TagInfo.java      8 Aug 2003 19:37:38 
-0000
@@ -92,7 +92,7 @@
     public static final String BODY_CONTENT_SCRIPTLESS = "SCRIPTLESS";
 
     /**
-     * Constructor for TagInfo from data in the JSP 2.0 format for TLD.
+     * Constructor for TagInfo from data in the JSP 1.1 format for TLD.
      * This class is to be instantiated only from the TagLibrary code
      * under request from some JSP code that is parsing a
      * TLD (Tag Library Descriptor).

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to