cziegeler 02/04/22 03:51:51
Modified: . build.xml
src/java/org/apache/cocoon/components/source URLSource.java
Log:
Fixing dependency to servlet 2.3
Revision Changes Path
1.201 +6 -0 xml-cocoon2/build.xml
Index: build.xml
===================================================================
RCS file: /home/cvs/xml-cocoon2/build.xml,v
retrieving revision 1.200
retrieving revision 1.201
diff -u -r1.200 -r1.201
--- build.xml 18 Apr 2002 13:48:40 -0000 1.200
+++ build.xml 22 Apr 2002 10:51:51 -0000 1.201
@@ -371,6 +371,10 @@
property="servlet.present"
classname="javax.servlet.http.HttpServlet"/>
+ <class-available classpathref="classpath"
+ property="servlet23.present"
+ classname="javax.servlet.http.HttpServletRequestWrapper"/>
+
<class-available classpathref="classpath"
property="bsf.present"
classname="com.ibm.bsf.BSFException"/>
@@ -843,6 +847,8 @@
<exclude name="**/XMLDB*.java" unless="xmldb.present"/>
<exclude name="**/DbXML*.java" unless="xmldb.present"/>
+
+ <exclude name="**/servlet/*Filter*.java" unless="servlet23.present"/>
</fileset>
</copy>
</target>
1.15 +1 -19
xml-cocoon2/src/java/org/apache/cocoon/components/source/URLSource.java
Index: URLSource.java
===================================================================
RCS file:
/home/cvs/xml-cocoon2/src/java/org/apache/cocoon/components/source/URLSource.java,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- URLSource.java 19 Apr 2002 11:02:57 -0000 1.14
+++ URLSource.java 22 Apr 2002 10:51:51 -0000 1.15
@@ -88,7 +88,7 @@
* Description of a source which is described by an URL.
*
* @author <a href="mailto:[EMAIL PROTECTED]">Carsten Ziegeler</a>
- * @version CVS $Id: URLSource.java,v 1.14 2002/04/19 11:02:57 cziegeler Exp $
+ * @version CVS $Id: URLSource.java,v 1.15 2002/04/22 10:51:51 cziegeler Exp $
*/
public class URLSource extends AbstractStreamSource {
@@ -102,9 +102,6 @@
/** The content length */
private long contentLength;
- /** Is the content html or xml? */
- private boolean isHTMLContent = false;
-
/** The system id */
private String systemId;
@@ -134,19 +131,10 @@
super(manager);
this.systemId = url.toExternalForm();
this.isFile = systemId.startsWith(FILE);
- if (this.isFile == true) {
- if (systemId.endsWith(".htm") || systemId.endsWith(".html")) {
- this.isHTMLContent = true;
- }
- }
this.url = url;
this.gotInfos = false;
}
- protected boolean isHTMLContent() {
- return this.isHTMLContent;
- }
-
/**
* Get the last modification date and content length of the source.
* Any exceptions are ignored.
@@ -267,16 +255,10 @@
out.write(postString.getBytes());
out.close();
}
- if ("text/html".equals(httpCon.getContentType()) == true) {
- this.isHTMLContent = true;
- }
input = httpCon.getInputStream();
this.connection = null; // make sure a new connection is
created next time
return input;
}
- }
- if ("text/html".equals(this.connection.getContentType()) == true) {
- this.isHTMLContent = true;
}
input = this.connection.getInputStream();
this.connection = null; // make sure a new connection is created
next time
----------------------------------------------------------------------
In case of troubles, e-mail: [EMAIL PROTECTED]
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]