abdera-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From roo...@apache.org
Subject svn commit: r437883 - /incubator/abdera/java/trunk/server/src/main/java/org/apache/abdera/server/servlet/ServletRequestContext.java
Date Tue, 29 Aug 2006 00:03:56 GMT
Author: rooneg
Date: Mon Aug 28 17:03:55 2006
New Revision: 437883

URL: http://svn.apache.org/viewvc?rev=437883&view=rev
Log:
Clean up ServletRequestContext a bit.

[ in server/src/main/java/org/apache/abdera/server/servlet ]

* ServletRequestContext.java
  (getPathInfo): Add a space after the if.
  (get_ccp): Don't call getCacheControl() twice when we don't need to,
   and add a space after the for.

Modified:
    incubator/abdera/java/trunk/server/src/main/java/org/apache/abdera/server/servlet/ServletRequestContext.java

Modified: incubator/abdera/java/trunk/server/src/main/java/org/apache/abdera/server/servlet/ServletRequestContext.java
URL: http://svn.apache.org/viewvc/incubator/abdera/java/trunk/server/src/main/java/org/apache/abdera/server/servlet/ServletRequestContext.java?rev=437883&r1=437882&r2=437883&view=diff
==============================================================================
--- incubator/abdera/java/trunk/server/src/main/java/org/apache/abdera/server/servlet/ServletRequestContext.java
(original)
+++ incubator/abdera/java/trunk/server/src/main/java/org/apache/abdera/server/servlet/ServletRequestContext.java
Mon Aug 28 17:03:55 2006
@@ -130,7 +130,7 @@
   public URI getPathInfo() {
     try {
       String pathInfo = servletRequest.getPathInfo();
-      if(pathInfo == null)  {
+      if (pathInfo == null)  {
         pathInfo = "";
       }
       return new URI(pathInfo);
@@ -207,9 +207,8 @@
   private void get_ccp() {
     String cc = getCacheControl();
     if (cc != null) {
-      CacheControlParser ccparser = 
-        new CacheControlParser(getCacheControl());
-      for(String directive : ccparser) {
+      CacheControlParser ccparser = new CacheControlParser(cc);
+      for (String directive : ccparser) {
         directive = directive.toLowerCase();
         if (directive.equals("max-age")) {
           maxage = Long.parseLong(ccparser.getValue(directive));



Mime
View raw message