You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ki...@apache.org on 2003/05/12 18:52:10 UTC

cvs commit: jakarta-servletapi-5/jsr152/src/share/javax/servlet/jsp/tagext SimpleTag.java SimpleTagSupport.java

kinman      2003/05/12 09:52:10

  Modified:    jsr152/examples/jsp2/jspx basic.jspx
               jsr152/src/share/javax/servlet/jsp/tagext SimpleTag.java
                        SimpleTagSupport.java
  Log:
  - Patch by Mark Roth:
  
  jsr152/src/share/javax/servlet/jsp/tagext/SimpleTag.java
       - Removed ordering requirement for attribute setters.
       - Clarified that setJspBody() is not called if the action element
         is empty.
       - Clarified that setParent() is only invoked if this tag invocation
         is nested within another tag invocation.
  
  jsr152/src/share/javax/servlet/jsp/tagext/SimpleTagSupport.java
       - Clarified that setJspBody() is not called if the action element
         is empty.
       - Clarified that setParent() is only invoked if this tag invocation
         is nested within another tag invocation.
  
  jsr152/examples/jsp2/jspx/basic.jspx
       - Added xmlns="http://www.w3.org/1999/xhtml" to root element.
  
  Revision  Changes    Path
  1.3       +2 -1      jakarta-servletapi-5/jsr152/examples/jsp2/jspx/basic.jspx
  
  Index: basic.jspx
  ===================================================================
  RCS file: /home/cvs/jakarta-servletapi-5/jsr152/examples/jsp2/jspx/basic.jspx,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- basic.jspx	5 May 2003 17:00:55 -0000	1.2
  +++ basic.jspx	12 May 2003 16:52:09 -0000	1.3
  @@ -1,6 +1,7 @@
   <tags:xhtmlbasic xmlns:tags="urn:jsptagdir:/WEB-INF/tags"
                    xmlns:jsp="http://java.sun.com/JSP/Page"
  -                 xmlns:fmt="http://java.sun.com/jstl/fmt_rt">
  +                 xmlns:fmt="http://java.sun.com/jstl/fmt_rt"
  +		 xmlns="http://www.w3.org/1999/xhtml">
     <jsp:directive.page contentType="text/html" />
     <head>
       <title>JSPX - XHTML Basic Example</title>
  
  
  
  1.7       +11 -5     jakarta-servletapi-5/jsr152/src/share/javax/servlet/jsp/tagext/SimpleTag.java
  
  Index: SimpleTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-servletapi-5/jsr152/src/share/javax/servlet/jsp/tagext/SimpleTag.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- SimpleTag.java	28 Jan 2003 00:19:10 -0000	1.6
  +++ SimpleTag.java	12 May 2003 16:52:10 -0000	1.7
  @@ -89,13 +89,15 @@
    *       tag handlers, simple tag handlers are never cached and reused by
    *       the JSP container.</li>
    *   <li>The <code>setJspContext()</code> and <code>setParent()</code> 
  - *       methods are called by the container.</li>
  + *       methods are called by the container.  The <code>setParent()</code>
  + *       method is only called if the element is nested within another tag 
  + *       invocation.</li>
    *   <li>The setters for each attribute defined for this tag are called
  - *       by the container, in the order in which they appear in the JSP
  - *       page or Tag File.</li>
  + *       by the container.</li>
    *   <li>If a body exists, the <code>setJspBody()</code> method is called 
    *       by the container to set the body of this tag, as a 
  - *       <code>JspFragment</code>.</li>
  + *       <code>JspFragment</code>.  If the action element is empty in
  + *       the page, this method is not called at all.</li>
    *   <li>The <code>doTag()</code> method is called by the container.  All
    *       tag logic, iteration, body evaluations, etc. occur in this 
    *       method.</li>
  @@ -135,6 +137,9 @@
       
       /**
        * Sets the parent of this tag, for collaboration purposes.
  +     * <p>
  +     * The container invokes this method only if this tag invocation is 
  +     * nested within another tag invocation.
        *
        * @param parent the tag that encloses this tag
        */
  @@ -161,7 +166,8 @@
        * invoked zero or more times by the tag handler. 
        * <p>
        * This method is invoked by the JSP page implementation 
  -     * object prior to <code>doTag()</code>. 
  +     * object prior to <code>doTag()</code>.  If the action element is
  +     * empty in the page, this method is not called at all.
        * 
        * @param jspBody The fragment encapsulating the body of this tag.
        */ 
  
  
  
  1.7       +7 -3      jakarta-servletapi-5/jsr152/src/share/javax/servlet/jsp/tagext/SimpleTagSupport.java
  
  Index: SimpleTagSupport.java
  ===================================================================
  RCS file: /home/cvs/jakarta-servletapi-5/jsr152/src/share/javax/servlet/jsp/tagext/SimpleTagSupport.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- SimpleTagSupport.java	31 Mar 2003 17:52:26 -0000	1.6
  +++ SimpleTagSupport.java	12 May 2003 16:52:10 -0000	1.7
  @@ -111,6 +111,9 @@
       
       /**
        * Sets the parent of this tag, for collaboration purposes.
  +     * <p>
  +     * The container invokes this method only if this tag invocation is
  +     * nested within another tag invocation.
        *
        * @param parent the tag that encloses this tag
        */
  @@ -151,8 +154,9 @@
       /** 
        * Stores the provided JspFragment.
        *
  -     * @param jspBody The fragment encapsulating the body of this tag, or
  -     *     null if this tag as a body content type of empty.
  +     * @param jspBody The fragment encapsulating the body of this tag.
  +     *     If the action element is empty in the page, this method is 
  +     *     not called at all.
        * @see SimpleTag#setJspBody
        */ 
       public void setJspBody( JspFragment jspBody ) {
  @@ -163,7 +167,7 @@
        * Returns the body passed in by the container via setJspBody.
        *
        * @return the fragment encapsulating the body of this tag, or
  -     *    null if this tag has a body content type of empty.
  +     *    null if the action element is empty in the page.
        */
       protected JspFragment getJspBody() {
           return this.jspBody;
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org