abdera-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jmsn...@apache.org
Subject svn commit: r442796 - in /incubator/abdera/java/trunk: core/src/main/java/org/apache/abdera/factory/ core/src/main/java/org/apache/abdera/util/ parser/src/main/java/org/apache/abdera/parser/stax/
Date Wed, 13 Sep 2006 02:10:20 GMT
Author: jmsnell
Date: Tue Sep 12 19:10:20 2006
New Revision: 442796

URL: http://svn.apache.org/viewvc?view=rev&rev=442796
Log:
APP Draft -10 introduces a new APP Categories Document Type

Modified:
    incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/factory/Factory.java
    incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/util/Constants.java
    incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/util/MimeTypeHelper.java
    incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMFactory.java

Modified: incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/factory/Factory.java
URL: http://svn.apache.org/viewvc/incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/factory/Factory.java?view=diff&rev=442796&r1=442795&r2=442796
==============================================================================
--- incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/factory/Factory.java
(original)
+++ incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/factory/Factory.java
Tue Sep 12 19:10:20 2006
@@ -460,7 +460,7 @@
   /**
    * Create a new Categories element as a child of the given Element
    */
-  Categories newCategories(Element parent);
+  Categories newCategories(Base parent);
   
   /**
    * Generate a new random UUID URI 

Modified: incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/util/Constants.java
URL: http://svn.apache.org/viewvc/incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/util/Constants.java?view=diff&rev=442796&r1=442795&r2=442796
==============================================================================
--- incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/util/Constants.java (original)
+++ incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/util/Constants.java Tue
Sep 12 19:10:20 2006
@@ -42,6 +42,7 @@
   public static final String ATOM_MEDIA_TYPE      = "application/atom+xml";
   public static final String APP_MEDIA_TYPE       = "application/atomserv+xml";
   public static final String XML_MEDIA_TYPE       = "application/xml";
+  public static final String CAT_MEDIA_TYPE       = "application/atomcat+xml";
   public static final String MULTIPART_MEDIA_TYPE = "multipart/related";
   
   public static final String ATOM_NS              = "http://www.w3.org/2005/Atom";

Modified: incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/util/MimeTypeHelper.java
URL: http://svn.apache.org/viewvc/incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/util/MimeTypeHelper.java?view=diff&rev=442796&r1=442795&r2=442796
==============================================================================
--- incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/util/MimeTypeHelper.java
(original)
+++ incubator/abdera/java/trunk/core/src/main/java/org/apache/abdera/util/MimeTypeHelper.java
Tue Sep 12 19:10:20 2006
@@ -21,6 +21,7 @@
 import javax.activation.MimeTypeParseException;
 
 import org.apache.abdera.model.Base;
+import org.apache.abdera.model.Categories;
 import org.apache.abdera.model.Document;
 import org.apache.abdera.model.Element;
 import org.apache.abdera.model.Entry;
@@ -94,6 +95,8 @@
           type = Constants.ATOM_MEDIA_TYPE;
         else if (el instanceof Service)
           type = Constants.APP_MEDIA_TYPE;
+        else if (el instanceof Categories)
+          type = Constants.CAT_MEDIA_TYPE;
         else 
           type = Constants.XML_MEDIA_TYPE;
       }

Modified: incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMFactory.java
URL: http://svn.apache.org/viewvc/incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMFactory.java?view=diff&rev=442796&r1=442795&r2=442796
==============================================================================
--- incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMFactory.java
(original)
+++ incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMFactory.java
Tue Sep 12 19:10:20 2006
@@ -858,10 +858,11 @@
   }
 
   public Categories newCategories() {
-    return newCategories(null);
+    Document<Categories> doc = newDocument();
+    return newCategories(doc);
   }
 
-  public Categories newCategories(Element parent) {
+  public Categories newCategories(Base parent) {
     return new FOMCategories((OMContainer)parent, this);
   }
 



Mime
View raw message