You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by kk...@apache.org on 2011/11/07 10:42:56 UTC
svn commit: r1198677 - /tomcat/trunk/java/org/apache/catalina/Globals.java
Author: kkolinko
Date: Mon Nov 7 09:42:55 2011
New Revision: 1198677
URL: http://svn.apache.org/viewvc?rev=1198677&view=rev
Log:
Add constants for the request attribute names used by Comet and Sendfile support.
Modified:
tomcat/trunk/java/org/apache/catalina/Globals.java
Modified: tomcat/trunk/java/org/apache/catalina/Globals.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/Globals.java?rev=1198677&r1=1198676&r2=1198677&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/Globals.java (original)
+++ tomcat/trunk/java/org/apache/catalina/Globals.java Mon Nov 7 09:42:55 2011
@@ -156,6 +156,76 @@ public final class Globals {
/**
+ * The request attribute that is set to the value of {@code Boolean.TRUE}
+ * if connector processing this request supports Comet API.
+ */
+ public static final String COMET_SUPPORTED_ATTR =
+ "org.apache.tomcat.comet.support";
+
+
+ /**
+ * The request attribute that is set to the value of {@code Boolean.TRUE}
+ * if connector processing this request supports setting
+ * per-connection request timeout through Comet API.
+ *
+ * @see org.apache.catalina.comet.CometEvent#setTimeout(int)
+ */
+ public static final String COMET_TIMEOUT_SUPPORTED_ATTR =
+ "org.apache.tomcat.comet.timeout.support";
+
+
+ /**
+ * The request attribute that can be set to a value of type
+ * {@code java.lang.Integer} to specify per-connection request
+ * timeout for Comet API. The value is in milliseconds.
+ *
+ * @see org.apache.catalina.comet.CometEvent#setTimeout(int)
+ */
+ public static final String COMET_TIMEOUT_ATTR =
+ "org.apache.tomcat.comet.timeout";
+
+
+ /**
+ * The request attribute that is set to the value of {@code Boolean.TRUE}
+ * if connector processing this request supports use of sendfile.
+ */
+ public static final String SENDFILE_SUPPORTED_ATTR =
+ "org.apache.tomcat.sendfile.support";
+
+
+ /**
+ * The request attribute that can be used by a servlet to pass
+ * to the connector the name of the file that is to be served
+ * by sendfile. The value should be {@code java.lang.String}
+ * that is {@code File.getCanonicalPath()} of the file to be served.
+ */
+ public static final String SENDFILE_FILENAME_ATTR =
+ "org.apache.tomcat.sendfile.filename";
+
+
+ /**
+ * The request attribute that can be used by a servlet to pass
+ * to the connector the start offset of the part of a file
+ * that is to be served by sendfile. The value should be
+ * {@code java.lang.Long}. To serve complete file
+ * the value should be {@code Long.valueOf(0)}.
+ */
+ public static final String SENDFILE_FILE_START_ATTR =
+ "org.apache.tomcat.sendfile.start";
+
+
+ /**
+ * The request attribute that can be used by a servlet to pass
+ * to the connector the end offset (not including) of the part
+ * of a file that is to be served by sendfile. The value should be
+ * {@code java.lang.Long}. To serve complete file
+ * the value should be equal to the length of the file.
+ */
+ public static final String SENDFILE_FILE_END_ATTR =
+ "org.apache.tomcat.sendfile.end";
+
+
+ /**
* The master flag which controls strict servlet specification
* compliance.
*/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org