tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Keith Wannamaker" <Ke...@Wannamaker.org>
Subject RE: TC 3.3 >= m3 Request.setRequestUri
Date Wed, 08 Aug 2001 14:42:59 GMT
| -----Original Message-----
| From: cmanolache@yahoo.com [mailto:cmanolache@yahoo.com]
| Sent: Wednesday, August 08, 2001 11:16 AM
| To: tomcat-dev@jakarta.apache.org
| Subject: Re: TC 3.3 >= m3 Request.setRequestUri
| 
| 
| Hi Keith,
| 
| After String->MessageByte, instead of storing the request
| info as String, with getFoo/setFoo methods, we use
| a MessageBytes - which is a modifiable object.
| 
| I don't see the point of replacing the field itself, but of
| course we can do that if you really need it.
| 
| Costin

Hi Costin,

Oh, no, not at all, I understand now.

However, what do you think about keeping the old String
methods for compatibility with 3.2 interceptors?  
Something like:

--- Request.java	2001/08/06 15:45:25	1.106
+++ Request.java	2001/08/08 15:40:07
@@ -309,9 +309,29 @@
     public MessageBytes method() {
 	return methodMB;
     }

+    /** @deprecated After Tomcat 3.2, use {@link #method()} instead */
+    public String getMethod() {
+	return methodMB.toString();
+    }
+
+    /** @deprecated After Tomcat 3.2, use {@link #method()} instead */
+    public void setMethod(String method) {
+	methodMB.setString(method);
+    }
+
     public MessageBytes requestURI() {
 	return uriMB;
+    }
+
+    /** @deprecated After Tomcat 3.2, use {@link #requestURI()} instead */
+    public String getRequestURI() {
+	return uriMB.toString();
+    }
+
+    /** @deprecated After Tomcat 3.2, use {@link #requestURI()} instead */
+    public void setRequestURI(String r) {
+	uriMB.setString(r);
     }
 
     public MessageBytes unparsedURI() {


Keith



Mime
View raw message