Author: chris.laprun(a)jboss.com
Date: 2011-12-09 05:27:14 -0500 (Fri, 09 Dec 2011)
New Revision: 8228
Modified:
components/wsrp/trunk/producer/src/main/java/org/gatein/wsrp/producer/handlers/processors/WSRPRequestContext.java
Log:
- GTNWSRP-274: Default implementation should return -1 instead of throwing an exception.
Modified:
components/wsrp/trunk/producer/src/main/java/org/gatein/wsrp/producer/handlers/processors/WSRPRequestContext.java
===================================================================
---
components/wsrp/trunk/producer/src/main/java/org/gatein/wsrp/producer/handlers/processors/WSRPRequestContext.java 2011-12-09
04:04:56 UTC (rev 8227)
+++
components/wsrp/trunk/producer/src/main/java/org/gatein/wsrp/producer/handlers/processors/WSRPRequestContext.java 2011-12-09
10:27:14 UTC (rev 8228)
@@ -65,7 +65,7 @@
public int getContentLength()
{
- throw new UnsupportedOperationException("Not currently supported");
+ return -1;
}
public BufferedReader getReader() throws IOException
@@ -130,6 +130,12 @@
{
return contentType;
}
+
+ @Override
+ public int getContentLength()
+ {
+ return 0; // todo: is it really the case or should it be -1?
+ }
}
static class WSRPMultiRequestContext extends WSRPRequestContext