bloritsch 01/06/12 08:49:34
Modified: src/org/apache/cocoon/generation Tag: cocoon_20_branch
StreamGenerator.java
Log:
Format changes
Revision Changes Path
No revision
No revision
1.1.2.3 +12 -11
xml-cocoon2/src/org/apache/cocoon/generation/StreamGenerator.java
Index: StreamGenerator.java
===================================================================
RCS file:
/home/cvs/xml-cocoon2/src/org/apache/cocoon/generation/StreamGenerator.java,v
retrieving revision 1.1.2.2
retrieving revision 1.1.2.3
diff -u -r1.1.2.2 -r1.1.2.3
--- StreamGenerator.java 2001/06/12 15:47:37 1.1.2.2
+++ StreamGenerator.java 2001/06/12 15:49:32 1.1.2.3
@@ -49,7 +49,7 @@
* number of bytes read is equal to the getContentLength() value.
*
* @author <a href="mailto:[EMAIL PROTECTED]">Kinga Dziembowski</a>
- * @version $Revision: 1.1.2.2 $ $Date: 2001/06/12 15:47:37 $
+ * @version $Revision: 1.1.2.3 $ $Date: 2001/06/12 15:49:32 $
*/
public class StreamGenerator extends ComposerGenerator {
public static final String CLASS = StreamGenerator.class.getName();
@@ -86,16 +86,17 @@
if
(request.getContentType().equals("application/x-www-form-urlencoded")) {
String sXml = request.getParameter(parameter);
inputSource = new InputSource(new StringReader(sXml));
- } else if (request.getContentType().equals("text/plain") ||
request.getContentType().equals("text/xml") ||
- request.getContentType().equals("application/xml")) {
- len = request.getContentLength();
-
- if (len > 0) {
- PostInputStream anStream = new
PostInputStream(request.getInputStream(), len);
- inputSource = new InputSource(anStream);
- } else {
- throw new IOException("getContentLen() == 0");
- }
+ } else if (request.getContentType().equals("text/plain") ||
+ request.getContentType().equals("text/xml") ||
+ request.getContentType().equals("application/xml")) {
+ len = request.getContentLength();
+
+ if (len > 0) {
+ PostInputStream anStream = new
PostInputStream(request.getInputStream(), len);
+ inputSource = new InputSource(anStream);
+ } else {
+ throw new IOException("getContentLen() == 0");
+ }
} else {
throw new IOException("Unexpected getContentType(): " +
request.getContentType());
}
----------------------------------------------------------------------
In case of troubles, e-mail: [EMAIL PROTECTED]
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]