You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by bu...@apache.org on 2005/02/23 09:14:47 UTC
svn commit: r154983 -
jakarta/commons/proper/feedparser/trunk/src/java/org/apache/commons/feedparser/network/URLResourceRequest.java
Author: burton
Date: Wed Feb 23 00:14:47 2005
New Revision: 154983
URL: http://svn.apache.org/viewcvs?view=rev&rev=154983
Log:
support for Feed IM...
Modified:
jakarta/commons/proper/feedparser/trunk/src/java/org/apache/commons/feedparser/network/URLResourceRequest.java
Modified: jakarta/commons/proper/feedparser/trunk/src/java/org/apache/commons/feedparser/network/URLResourceRequest.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/feedparser/trunk/src/java/org/apache/commons/feedparser/network/URLResourceRequest.java?view=diff&r1=154982&r2=154983
==============================================================================
--- jakarta/commons/proper/feedparser/trunk/src/java/org/apache/commons/feedparser/network/URLResourceRequest.java (original)
+++ jakarta/commons/proper/feedparser/trunk/src/java/org/apache/commons/feedparser/network/URLResourceRequest.java Wed Feb 23 00:14:47 2005
@@ -49,7 +49,9 @@
public static final String GZIP_ENCODING = "gzip";
public static final String USER_AGENT_HEADER = "User-Agent";
-
+
+ public static boolean ENABLE_HTTP_DELTA_FEED_IM = false;
+
public static String USER_AGENT
= "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2.1; aggregator:FeedParser; http://jakarta.apache.org/commons/sandbox/feedparser/) Gecko/20021130";
@@ -155,8 +157,19 @@
if ( this.getIfModifiedSince() != -1 )
httpURLConn.setIfModifiedSince( this.getIfModifiedSince() );
- if ( getEtag() != null )
+ if ( getEtag() != null ) {
httpURLConn.setRequestProperty( IF_NONE_MATCH_HEADER, getEtag() );
+
+ //now support RFC3229 HTTP Delta
+ //A-IM: feed, gzip
+
+ if ( ENABLE_HTTP_DELTA_FEED_IM ) {
+
+ //note that this will return HTTP 226 if used.
+ httpURLConn.setRequestProperty( "A-IM", "feed, gzip" );
+ }
+
+ }
try {
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org