chemistry-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fguilla...@apache.org
Subject svn commit: r908547 - in /incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client: APPConnection.java APPObject.java
Date Wed, 10 Feb 2010 15:46:10 GMT
Author: fguillaume
Date: Wed Feb 10 15:46:10 2010
New Revision: 908547

URL: http://svn.apache.org/viewvc?rev=908547&view=rev
Log:
CMIS-108: add APPObject access to underlying APPObjectEntry

Modified:
    incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPConnection.java
    incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPObject.java

Modified: incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPConnection.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPConnection.java?rev=908547&r1=908546&r2=908547&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPConnection.java
(original)
+++ incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPConnection.java
Wed Feb 10 15:46:10 2010
@@ -15,6 +15,7 @@
  *     Bogdan Stefanescu, Nuxeo
  *     Florent Guillaume, Nuxeo
  *     Ugo Cei, Sourcesense
+ *     Chris Hubick
  */
 package org.apache.chemistry.atompub.client;
 
@@ -299,6 +300,8 @@
     protected APPObjectEntry getObjectEntry(ObjectId objectId) {
         if (objectId instanceof APPObjectEntry) {
             return (APPObjectEntry) objectId;
+        } else if (objectId instanceof APPObject) {
+            return ((APPObject) objectId).getEntry();
         }
         URITemplate uriTemplate = repository.getURITemplate(AtomPubCMIS.URITMPL_OBJECT_BY_ID);
         String href = uriTemplate.template;
@@ -560,8 +563,7 @@
         NameValuePairs params = new NameValuePairs();
         params.add(AtomPubCMIS.PARAM_SOURCE_FOLDER_ID,
                 sourceFolder == null ? "" : sourceFolder.getId());
-        return connector.postEntry(getPostHref(targetFolder), params,
-                entry);
+        return connector.postEntry(getPostHref(targetFolder), params, entry);
     }
 
     public void deleteObject(ObjectId object, boolean allVersions) {

Modified: incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPObject.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPObject.java?rev=908547&r1=908546&r2=908547&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPObject.java
(original)
+++ incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPObject.java
Wed Feb 10 15:46:10 2010
@@ -14,6 +14,7 @@
  * Authors:
  *     Bogdan Stefanescu, Nuxeo
  *     Florent Guillaume, Nuxeo
+ *     Chris Hubick
  */
 package org.apache.chemistry.atompub.client;
 
@@ -188,6 +189,10 @@
         return entry.getTypeId();
     }
 
+    public APPObjectEntry getEntry() {
+        return entry;
+    }
+
     public Type getType() {
         return type;
     }



Mime
View raw message