geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject svn commit: r807027 - in /geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet: ./ annotation/ http/
Date Sun, 23 Aug 2009 22:52:09 GMT
Author: djencks
Date: Sun Aug 23 22:52:08 2009
New Revision: 807027

URL: http://svn.apache.org/viewvc?rev=807027&view=rev
Log:
attempt to use the apparently out of date tck to improve compliance

Modified:
    geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletContext.java
    geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletRequestWrapper.java
    geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletResponseWrapper.java
    geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/HandlesTypes.java
    geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/MultipartConfig.java
    geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebFilter.java
    geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebInitParam.java
    geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebListener.java
    geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebServlet.java
    geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/HttpServletRequest.java
    geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/HttpServletRequestWrapper.java
    geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/Part.java

Modified: geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletContext.java
URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletContext.java?rev=807027&r1=807026&r2=807027&view=diff
==============================================================================
--- geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletContext.java
(original)
+++ geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletContext.java
Sun Aug 23 22:52:08 2009
@@ -61,7 +61,7 @@
     /**
      * @since Servlet 3.0
      */
-    String ORDERED_LIGS = "javax.servlet.context.orderedLibs";
+    String ORDERED_LIBS = "javax.servlet.context.orderedLibs";
     /**
      * @since Servlet 3.0
      */
@@ -672,12 +672,6 @@
     <T extends EventListener> T createListener(Class<T> clazz) throws ServletException;
 
     /**
-     * @param sessionCookieConfig configuration of session cookie
-     * @since 3.0
-     */
-    void setSessionCookieConfig(SessionCookieConfig sessionCookieConfig);
-
-    /**
      * @return configuration of session cookie
      * @since 3.0
      */

Modified: geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletRequestWrapper.java
URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletRequestWrapper.java?rev=807027&r1=807026&r2=807027&view=diff
==============================================================================
--- geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletRequestWrapper.java
(original)
+++ geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletRequestWrapper.java
Sun Aug 23 22:52:08 2009
@@ -367,5 +367,25 @@
         return this.request.getDispatcherType();
     }
 
+    public boolean isWrapperFor(Class wrappedType) {
+        if (this.request.getClass().isAssignableFrom(wrappedType)) {
+            return true;
+        }
+        if (this.request instanceof ServletRequestWrapper) {
+            return ((ServletRequestWrapper)this.request).isWrapperFor(wrappedType);
+        }
+        return false;
+    }
+
+    public boolean isWrapperFor(ServletRequest instance) {
+        if (instance == this.request) {
+            return true;
+        }
+        if (this.request instanceof ServletRequestWrapper) {
+            return ((ServletRequestWrapper)this.request).isWrapperFor(instance);
+        }
+        return false;
+    }
+
 }
 

Modified: geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletResponseWrapper.java
URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletResponseWrapper.java?rev=807027&r1=807026&r2=807027&view=diff
==============================================================================
--- geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletResponseWrapper.java
(original)
+++ geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/ServletResponseWrapper.java
Sun Aug 23 22:52:08 2009
@@ -198,6 +198,27 @@
         return this.response.getLocale();
     }
 
+    public boolean isWrapperFor(Class wrappedType) {
+        if (this.response.getClass().isAssignableFrom(wrappedType)) {
+            return true;
+        }
+        if (this.response instanceof ServletResponseWrapper) {
+            return ((ServletResponseWrapper)this.response).isWrapperFor(wrappedType);
+        }
+        return false;
+    }
+
+    public boolean isWrapperFor(ServletResponse instance) {
+        if (instance == this.response) {
+            return true;
+        }
+        if (this.response instanceof ServletResponseWrapper) {
+            return ((ServletResponseWrapper)this.response).isWrapperFor(instance);
+        }
+        return false;
+    }
+
+
 }
 
 

Modified: geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/HandlesTypes.java
URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/HandlesTypes.java?rev=807027&r1=807026&r2=807027&view=diff
==============================================================================
--- geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/HandlesTypes.java
(original)
+++ geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/HandlesTypes.java
Sun Aug 23 22:52:08 2009
@@ -20,10 +20,10 @@
 
 package javax.servlet.annotation;
 
-import java.lang.annotation.Target;
+import java.lang.annotation.ElementType;
 import java.lang.annotation.Retention;
 import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.ElementType;
+import java.lang.annotation.Target;
 
 /**
  * @version $Rev$ $Date$

Modified: geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/MultipartConfig.java
URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/MultipartConfig.java?rev=807027&r1=807026&r2=807027&view=diff
==============================================================================
--- geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/MultipartConfig.java
(original)
+++ geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/MultipartConfig.java
Sun Aug 23 22:52:08 2009
@@ -20,10 +20,10 @@
 
 package javax.servlet.annotation;
 
-import java.lang.annotation.Target;
 import java.lang.annotation.ElementType;
 import java.lang.annotation.Retention;
 import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
 
 /**
  * @version $Rev$ $Date$
@@ -34,12 +34,12 @@
 @Retention(value = RetentionPolicy.RUNTIME)
 public @interface MultipartConfig {
 
-    int fileSizeThreshhold() default 0;
+    int fileSizeThreshold() default 0;
 
     String location() default "";
 
-    long maxFileSize() default 0L;
+    long maxFileSize() default -1L;
 
-    long maxRequestSize() default 0L;
+    long maxRequestSize() default -1L;
 
 }

Modified: geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebFilter.java
URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebFilter.java?rev=807027&r1=807026&r2=807027&view=diff
==============================================================================
--- geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebFilter.java
(original)
+++ geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebFilter.java
Sun Aug 23 22:52:08 2009
@@ -24,6 +24,7 @@
 import java.lang.annotation.ElementType;
 import java.lang.annotation.Retention;
 import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Documented;
 
 import javax.servlet.DispatcherType;
 
@@ -32,11 +33,12 @@
  * @since 3.0
  */
 
+@Documented
 @Target(value= ElementType.TYPE)
 @Retention(value= RetentionPolicy.RUNTIME)
 public @interface WebFilter {
 
-    boolean asyncSupported();
+    boolean asyncSupported() default false;
 
     String description() default "";
 

Modified: geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebInitParam.java
URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebInitParam.java?rev=807027&r1=807026&r2=807027&view=diff
==============================================================================
--- geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebInitParam.java
(original)
+++ geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebInitParam.java
Sun Aug 23 22:52:08 2009
@@ -24,11 +24,13 @@
 import java.lang.annotation.ElementType;
 import java.lang.annotation.Retention;
 import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Documented;
 
 /**
  * @version $Rev$ $Date$
  */
 
+@Documented
 @Target(value= ElementType.TYPE)
 @Retention(value= RetentionPolicy.RUNTIME)
 public @interface WebInitParam {

Modified: geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebListener.java
URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebListener.java?rev=807027&r1=807026&r2=807027&view=diff
==============================================================================
--- geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebListener.java
(original)
+++ geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebListener.java
Sun Aug 23 22:52:08 2009
@@ -24,12 +24,14 @@
 import java.lang.annotation.ElementType;
 import java.lang.annotation.Retention;
 import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Documented;
 
 /**
  * @version $Rev$ $Date$
  * @since 3.0
  */
 
+@Documented
 @Target(value= ElementType.TYPE)
 @Retention(value= RetentionPolicy.RUNTIME)
 public @interface WebListener {

Modified: geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebServlet.java
URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebServlet.java?rev=807027&r1=807026&r2=807027&view=diff
==============================================================================
--- geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebServlet.java
(original)
+++ geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/annotation/WebServlet.java
Sun Aug 23 22:52:08 2009
@@ -24,12 +24,14 @@
 import java.lang.annotation.ElementType;
 import java.lang.annotation.Retention;
 import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Documented;
 
 /**
  * @version $Rev$ $Date$
  * @since 3.0
  */
 
+@Documented
 @Target(value= ElementType.TYPE)
 @Retention(value= RetentionPolicy.RUNTIME)
 public @interface WebServlet {

Modified: geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/HttpServletRequest.java
URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/HttpServletRequest.java?rev=807027&r1=807026&r2=807027&view=diff
==============================================================================
--- geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/HttpServletRequest.java
(original)
+++ geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/HttpServletRequest.java
Sun Aug 23 22:52:08 2009
@@ -23,6 +23,7 @@
 import javax.servlet.ServletException;
 
 import java.util.Enumeration;
+import java.io.IOException;
 
 /**
  * Extends the {@link javax.servlet.ServletRequest} interface
@@ -59,9 +60,10 @@
      *
      * @param response response to use to conduct a dialog if necessary
      * @return whether authentication was successful
+     * @throws javax.servlet.ServletException if something goes wrong
      * @since 3.0
      */
-    boolean authenticate(HttpServletResponse response);
+    boolean authenticate(HttpServletResponse response) throws IOException, ServletException;
 
     /**
      * Returns the name of the authentication scheme used to protect
@@ -238,15 +240,17 @@
     /**
      * @param name part name
      * @return named part
+     * @throws javax.servlet.ServletException if something goes wrong
      * @since 3.0
      */
-    Part getPart(String name);
+    Part getPart(String name) throws IOException, ServletException;
 
     /**
      * @return all the parts
+     * @throws javax.servlet.ServletException if something goes wrong
      * @since 3.0
      */
-    Iterable<Part> getParts();
+    Iterable<Part> getParts() throws IOException, ServletException;
 
     /**
      * Returns any extra path information associated with

Modified: geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/HttpServletRequestWrapper.java
URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/HttpServletRequestWrapper.java?rev=807027&r1=807026&r2=807027&view=diff
==============================================================================
--- geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/HttpServletRequestWrapper.java
(original)
+++ geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/HttpServletRequestWrapper.java
Sun Aug 23 22:52:08 2009
@@ -23,6 +23,7 @@
 import javax.servlet.ServletException;
 
 import java.util.Enumeration;
+import java.io.IOException;
 
 /**
  * Provides a convenient implementation of the HttpServletRequest interface that
@@ -53,7 +54,7 @@
         return (HttpServletRequest) super.getRequest();
     }
 
-    public boolean authenticate(HttpServletResponse response) {
+    public boolean authenticate(HttpServletResponse response) throws IOException, ServletException
{
         return getHttpServletRequest().authenticate(response);
     }
 
@@ -123,11 +124,11 @@
         return getHttpServletRequest().getMethod();
     }
 
-    public Part getPart(String name) {
+    public Part getPart(String name) throws IOException, ServletException {
         return getHttpServletRequest().getPart(name);
     }
 
-    public Iterable<Part> getParts() {
+    public Iterable<Part> getParts() throws IOException, ServletException {
         return getHttpServletRequest().getParts();
     }
 

Modified: geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/Part.java
URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/Part.java?rev=807027&r1=807026&r2=807027&view=diff
==============================================================================
--- geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/Part.java
(original)
+++ geronimo/specs/trunk/geronimo-servlet_3.0_spec/src/main/java/javax/servlet/http/Part.java
Sun Aug 23 22:52:08 2009
@@ -35,11 +35,11 @@
 
     String getContentType();
 
-    String getHeader();
+    String getHeader(String headerName);
 
     Iterable<String> getHeaderNames();
 
-    Iterable<String> getHeaders();
+    Iterable<String> getHeaders(String headerName);
 
     InputStream getInputStream() throws IOException;
 



Mime
View raw message