chemistry-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From f...@apache.org
Subject svn commit: r1413683 - in /chemistry/opencmis/trunk: chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/ chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemi...
Date Mon, 26 Nov 2012 15:30:27 GMT
Author: fmui
Date: Mon Nov 26 15:30:23 2012
New Revision: 1413683

URL: http://svn.apache.org/viewvc?rev=1413683&view=rev
Log:
First batch of high-level API changes for CMIS 1.1

Added:
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Item.java   (with props)
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/ItemType.java   (with props)
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/SecondaryType.java   (with props)
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/ItemImpl.java   (with props)
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/objecttype/ItemTypeImpl.java   (with props)
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/objecttype/SecondaryTypeImpl.java   (with props)
    chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/SecondaryTypeIds.java   (with props)
Modified:
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/CmisObjectProperties.java
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Document.java
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/DocumentProperties.java
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Session.java
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/TransientCmisObject.java
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/AbstractCmisObject.java
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/AbstractTransientCmisObject.java
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/DocumentImpl.java
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/SessionImpl.java
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/TransientDocumentImpl.java
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/repository/ObjectFactoryImpl.java
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/test/java/org/apache/chemistry/opencmis/client/runtime/CmisObjectMock.java
    chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/PropertyIds.java

Modified: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/CmisObjectProperties.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/CmisObjectProperties.java?rev=1413683&r1=1413682&r2=1413683&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/CmisObjectProperties.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/CmisObjectProperties.java Mon Nov 26 15:30:23 2012
@@ -65,6 +65,12 @@ public interface CmisObjectProperties {
     String getName();
 
     /**
+     * Returns the description of this CMIS object (CMIS property
+     * <code>cmis:description</code>).
+     */
+    String getDescription();
+
+    /**
      * Returns the user who created this CMIS object (CMIS property
      * <code>cmis:createdBy</code>).
      */
@@ -107,6 +113,12 @@ public interface CmisObjectProperties {
     ObjectType getType();
 
     /**
+     * Returns the secondary types of this CMIS object (object types identified
+     * by <code>cmis:secondaryObjectTypeIds</code>).
+     */
+    List<SecondaryType> getSecondaryTypes();
+
+    /**
      * Returns the change token (CMIS property <code>cmis:changeToken</code>).
      */
     String getChangeToken();

Modified: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Document.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Document.java?rev=1413683&r1=1413682&r2=1413683&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Document.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Document.java Mon Nov 26 15:30:23 2012
@@ -112,6 +112,29 @@ public interface Document extends Fileab
     ObjectId setContentStream(ContentStream contentStream, boolean overwrite, boolean refresh);
 
     /**
+     * Appends a content stream to the content stream of the document and
+     * refreshes this object afterwards. If the repository created a new
+     * version, this new document is returned. Otherwise the current document is
+     * returned.
+     * 
+     * The stream in <code>contentStream</code> is consumed but not closed by
+     * this method.
+     * 
+     * @return the updated document
+     */
+    Document appendContentStream(ContentStream contentStream);
+
+    /**
+     * Appends a content stream to the content stream of the document.
+     * 
+     * The stream in <code>contentStream</code> is consumed but not closed by
+     * this method.
+     * 
+     * @return the updated object id
+     */
+    ObjectId appendContentStream(ContentStream contentStream, boolean refresh);
+
+    /**
      * Removes the current content stream from the document and refreshes this
      * object afterwards. If the repository created a new version, this new
      * document is returned. Otherwise the current document is returned.

Modified: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/DocumentProperties.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/DocumentProperties.java?rev=1413683&r1=1413682&r2=1413683&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/DocumentProperties.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/DocumentProperties.java Mon Nov 26 15:30:23 2012
@@ -20,7 +20,7 @@ package org.apache.chemistry.opencmis.cl
 
 /**
  * Accessors to CMIS document properties.
- *
+ * 
  * @see CmisObjectProperties
  */
 public interface DocumentProperties {
@@ -45,13 +45,18 @@ public interface DocumentProperties {
     Boolean isMajorVersion();
 
     /**
-     * Returns
-     * <code>true</code> if this CMIS object is the latest major version (CMIS property
-     * <code>cmis:isLatestMajorVersion</code>).
+     * Returns <code>true</code> if this CMIS object is the latest major version
+     * (CMIS property <code>cmis:isLatestMajorVersion</code>).
      */
     Boolean isLatestMajorVersion();
 
     /**
+     * Returns <code>true</code> if this CMIS object is the PWC (CMIS property
+     * <code>cmis:isPrivateWorkingCopy</code>).
+     */
+    Boolean isPrivateWorkingCopy();
+
+    /**
      * Returns the version label (CMIS property <code>cmis:versionLabel</code>).
      */
     String getVersionLabel();
@@ -63,9 +68,8 @@ public interface DocumentProperties {
     String getVersionSeriesId();
 
     /**
-     * Returns
-     * <code>true</code> if this version series is checked out (CMIS property
-     * <code>cmis:isVersionSeriesCheckedOut</code>).
+     * Returns <code>true</code> if this version series is checked out (CMIS
+     * property <code>cmis:isVersionSeriesCheckedOut</code>).
      */
     Boolean isVersionSeriesCheckedOut();
 

Added: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Item.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Item.java?rev=1413683&view=auto
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Item.java (added)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Item.java Mon Nov 26 15:30:23 2012
@@ -0,0 +1,28 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.chemistry.opencmis.client.api;
+
+/**
+ * CMIS Item.
+ * 
+ * Introduced in CMIS 1.1.
+ */
+public interface Item extends FileableCmisObject {
+
+}

Propchange: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Item.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/ItemType.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/ItemType.java?rev=1413683&view=auto
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/ItemType.java (added)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/ItemType.java Mon Nov 26 15:30:23 2012
@@ -0,0 +1,26 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.chemistry.opencmis.client.api;
+
+/**
+ * Item Object Type.
+ */
+public interface ItemType extends ObjectType {
+
+}

Propchange: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/ItemType.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/SecondaryType.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/SecondaryType.java?rev=1413683&view=auto
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/SecondaryType.java (added)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/SecondaryType.java Mon Nov 26 15:30:23 2012
@@ -0,0 +1,26 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.chemistry.opencmis.client.api;
+
+/**
+ * Secondary type.
+ */
+public interface SecondaryType extends ObjectType {
+
+}

Propchange: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/SecondaryType.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Session.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Session.java?rev=1413683&r1=1413682&r2=1413683&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Session.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/Session.java Mon Nov 26 15:30:23 2012
@@ -27,6 +27,7 @@ import java.util.Set;
 
 import org.apache.chemistry.opencmis.commons.data.Ace;
 import org.apache.chemistry.opencmis.commons.data.Acl;
+import org.apache.chemistry.opencmis.commons.data.BulkUpdateObjectIdAndChangeToken;
 import org.apache.chemistry.opencmis.commons.data.ContentStream;
 import org.apache.chemistry.opencmis.commons.data.RepositoryInfo;
 import org.apache.chemistry.opencmis.commons.enums.AclPropagation;
@@ -154,6 +155,21 @@ public interface Session extends Seriali
      */
     List<Tree<ObjectType>> getTypeDescendants(String typeId, int depth, boolean includePropertyDefinitions);
 
+    /**
+     * Creates a new type.
+     */
+    ObjectType createType(ObjectType type);
+
+    /**
+     * Updates an existing type.
+     */
+    ObjectType updateType(ObjectType type);
+
+    /**
+     * Deletes a type.
+     */
+    void deleteType(String typeId);
+
     // navigation
 
     /**
@@ -465,6 +481,12 @@ public interface Session extends Seriali
             RelationshipDirection relationshipDirection, ObjectType type, OperationContext context);
 
     /**
+     * Updates multiple objects in one request.
+     */
+    BulkUpdateObjectIdAndChangeToken bulkUpdateProperties(BulkUpdateObjectIdAndChangeToken objectIdsAndChangeToken,
+            Map<String, ?> properties, List<String> addSecondaryTypeIds, List<String> removeSecondaryTypeIds);
+
+    /**
      * Deletes an object and, if it is a document, all versions in the version
      * series.
      * 

Modified: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/TransientCmisObject.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/TransientCmisObject.java?rev=1413683&r1=1413682&r2=1413683&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/TransientCmisObject.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-api/src/main/java/org/apache/chemistry/opencmis/client/api/TransientCmisObject.java Mon Nov 26 15:30:23 2012
@@ -32,6 +32,8 @@ public interface TransientCmisObject ext
 
     void setName(String name);
 
+    void setDescription(String description);
+
     <T> void setPropertyValue(String id, Object value);
 
     // read-only

Modified: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/AbstractCmisObject.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/AbstractCmisObject.java?rev=1413683&r1=1413682&r2=1413683&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/AbstractCmisObject.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/AbstractCmisObject.java Mon Nov 26 15:30:23 2012
@@ -38,6 +38,7 @@ import org.apache.chemistry.opencmis.cli
 import org.apache.chemistry.opencmis.client.api.Property;
 import org.apache.chemistry.opencmis.client.api.Relationship;
 import org.apache.chemistry.opencmis.client.api.Rendition;
+import org.apache.chemistry.opencmis.client.api.SecondaryType;
 import org.apache.chemistry.opencmis.client.api.TransientCmisObject;
 import org.apache.chemistry.opencmis.commons.PropertyIds;
 import org.apache.chemistry.opencmis.commons.data.Ace;
@@ -63,6 +64,7 @@ public abstract class AbstractCmisObject
 
     private SessionImpl session;
     private ObjectType objectType;
+    private List<SecondaryType> secondaryTypes;
     private Map<String, Property<?>> properties;
     private AllowableActions allowableActions;
     private List<Rendition> renditions;
@@ -96,6 +98,7 @@ public abstract class AbstractCmisObject
 
         this.session = session;
         this.objectType = objectType;
+        this.secondaryTypes = null;
         this.extensions = new HashMap<ExtensionLevel, List<CmisExtensionElement>>();
         this.creationContext = new OperationContextImpl(context);
         this.refreshTimestamp = System.currentTimeMillis();
@@ -152,8 +155,26 @@ public abstract class AbstractCmisObject
                 }
             }
 
+            // get secondary types
+            if (properties.containsKey(PropertyIds.SECONDARY_OBJECT_TYPE_IDS)) {
+                @SuppressWarnings("unchecked")
+                List<String> stids = (List<String>) properties.get(PropertyIds.SECONDARY_OBJECT_TYPE_IDS).getValues();
+                if (stids != null && stids.size() > 0) {
+                    secondaryTypes = new ArrayList<SecondaryType>();
+                    for (String stid : stids) {
+                        if (stid != null) {
+                            ObjectType type = session.getTypeDefinition(stid);
+                            if (type instanceof SecondaryType) {
+                                secondaryTypes.add((SecondaryType) type);
+                            }
+                        }
+                    }
+                }
+            }
+
             extensions.put(ExtensionLevel.OBJECT, objectData.getExtensions());
         }
+
     }
 
     /**
@@ -385,6 +406,10 @@ public abstract class AbstractCmisObject
         return getPropertyValue(PropertyIds.NAME);
     }
 
+    public String getDescription() {
+        return getPropertyValue(PropertyIds.DESCRIPTION);
+    }
+
     public List<Property<?>> getProperties() {
         readLock();
         try {
@@ -423,6 +448,15 @@ public abstract class AbstractCmisObject
         }
     }
 
+    public List<SecondaryType> getSecondaryTypes() {
+        readLock();
+        try {
+            return this.secondaryTypes;
+        } finally {
+            readUnlock();
+        }
+    }
+
     // --- allowable actions ---
 
     public AllowableActions getAllowableActions() {

Modified: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/AbstractTransientCmisObject.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/AbstractTransientCmisObject.java?rev=1413683&r1=1413682&r2=1413683&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/AbstractTransientCmisObject.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/AbstractTransientCmisObject.java Mon Nov 26 15:30:23 2012
@@ -40,6 +40,7 @@ import org.apache.chemistry.opencmis.cli
 import org.apache.chemistry.opencmis.client.api.Property;
 import org.apache.chemistry.opencmis.client.api.Relationship;
 import org.apache.chemistry.opencmis.client.api.Rendition;
+import org.apache.chemistry.opencmis.client.api.SecondaryType;
 import org.apache.chemistry.opencmis.client.api.Session;
 import org.apache.chemistry.opencmis.client.api.TransientCmisObject;
 import org.apache.chemistry.opencmis.commons.PropertyIds;
@@ -185,6 +186,10 @@ public abstract class AbstractTransientC
         return object.getType();
     }
 
+    public List<SecondaryType> getSecondaryTypes() {
+        return object.getSecondaryTypes();
+    }
+
     public String getChangeToken() {
         return getPropertyValue(PropertyIds.CHANGE_TOKEN);
     }
@@ -217,6 +222,14 @@ public abstract class AbstractTransientC
         setPropertyValue(PropertyIds.NAME, name);
     }
 
+    public String getDescription() {
+        return getPropertyValue(PropertyIds.DESCRIPTION);
+    }
+
+    public void setDescription(String description) {
+        setPropertyValue(PropertyIds.DESCRIPTION, description);
+    }
+
     public List<Property<?>> getProperties() {
         return Collections.unmodifiableList(new ArrayList<Property<?>>(this.properties.values()));
     }

Modified: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/DocumentImpl.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/DocumentImpl.java?rev=1413683&r1=1413682&r2=1413683&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/DocumentImpl.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/DocumentImpl.java Mon Nov 26 15:30:23 2012
@@ -109,6 +109,10 @@ public class DocumentImpl extends Abstra
         return getPropertyValue(PropertyIds.IS_MAJOR_VERSION);
     }
 
+    public Boolean isPrivateWorkingCopy() {
+        return getPropertyValue(PropertyIds.IS_PRIVATE_WORKING_COPY);
+    }
+
     public Boolean isVersionSeriesCheckedOut() {
         return getPropertyValue(PropertyIds.IS_VERSION_SERIES_CHECKED_OUT);
     }
@@ -428,6 +432,46 @@ public class DocumentImpl extends Abstra
         return getSession().createObjectId(newObjectId);
     }
 
+    public Document appendContentStream(ContentStream contentStream) {
+        ObjectId objectId = appendContentStream(contentStream, true);
+        if (objectId == null) {
+            return null;
+        }
+
+        if (!getObjectId().equals(objectId.getId())) {
+            return (Document) getSession().getObject(objectId, getCreationContext());
+        }
+
+        return this;
+    }
+
+    public ObjectId appendContentStream(ContentStream contentStream, boolean refresh) {
+        String newObjectId = null;
+
+        readLock();
+        try {
+            Holder<String> objectIdHolder = new Holder<String>(getObjectId());
+            Holder<String> changeTokenHolder = new Holder<String>((String) getPropertyValue(PropertyIds.CHANGE_TOKEN));
+
+            getBinding().getObjectService().appendContentStream(getRepositoryId(), objectIdHolder, changeTokenHolder,
+                    getObjectFactory().convertContentStream(contentStream), null);
+
+            newObjectId = objectIdHolder.getValue();
+        } finally {
+            readUnlock();
+        }
+
+        if (refresh) {
+            refresh();
+        }
+
+        if (newObjectId == null) {
+            return null;
+        }
+
+        return getSession().createObjectId(newObjectId);
+    }
+
     public Document deleteContentStream() {
         ObjectId objectId = deleteContentStream(true);
         if (objectId == null) {

Added: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/ItemImpl.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/ItemImpl.java?rev=1413683&view=auto
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/ItemImpl.java (added)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/ItemImpl.java Mon Nov 26 15:30:23 2012
@@ -0,0 +1,37 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.chemistry.opencmis.client.runtime;
+
+import org.apache.chemistry.opencmis.client.api.Item;
+import org.apache.chemistry.opencmis.client.api.ObjectType;
+import org.apache.chemistry.opencmis.client.api.OperationContext;
+import org.apache.chemistry.opencmis.commons.data.ObjectData;
+
+public class ItemImpl extends AbstractFilableCmisObject implements Item {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * Constructor.
+     */
+    public ItemImpl(SessionImpl session, ObjectType objectType, ObjectData objectData, OperationContext context) {
+        initialize(session, objectType, objectData, context);
+    }
+
+}

Propchange: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/ItemImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/SessionImpl.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/SessionImpl.java?rev=1413683&r1=1413682&r2=1413683&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/SessionImpl.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/SessionImpl.java Mon Nov 26 15:30:23 2012
@@ -53,6 +53,7 @@ import org.apache.chemistry.opencmis.cli
 import org.apache.chemistry.opencmis.commons.SessionParameter;
 import org.apache.chemistry.opencmis.commons.data.Ace;
 import org.apache.chemistry.opencmis.commons.data.Acl;
+import org.apache.chemistry.opencmis.commons.data.BulkUpdateObjectIdAndChangeToken;
 import org.apache.chemistry.opencmis.commons.data.ContentStream;
 import org.apache.chemistry.opencmis.commons.data.ObjectData;
 import org.apache.chemistry.opencmis.commons.data.ObjectList;
@@ -544,6 +545,18 @@ public class SessionImpl implements Sess
         return result;
     }
 
+    public ObjectType createType(ObjectType type) {
+        throw new CmisNotSupportedException("Not implemented, yet");
+    }
+
+    public ObjectType updateType(ObjectType type) {
+        throw new CmisNotSupportedException("Not implemented, yet");
+    }
+
+    public void deleteType(String typeId) {
+        getBinding().getRepositoryService().deleteType(getRepositoryId(), typeId, null);
+    }
+
     public ItemIterable<QueryResult> query(final String statement, final boolean searchAllVersions) {
         return query(statement, searchAllVersions, getDefaultContext());
     }
@@ -898,6 +911,14 @@ public class SessionImpl implements Sess
         });
     }
 
+    // --- bulk update ---
+
+    public BulkUpdateObjectIdAndChangeToken bulkUpdateProperties(
+            BulkUpdateObjectIdAndChangeToken objectIdsAndChangeToken, Map<String, ?> properties,
+            List<String> addSecondaryTypeIds, List<String> removeSecondaryTypeIds) {
+        throw new CmisNotSupportedException("Not implemented, yet");
+    }
+
     // --- delete ---
 
     public void delete(ObjectId objectId) {

Modified: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/TransientDocumentImpl.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/TransientDocumentImpl.java?rev=1413683&r1=1413682&r2=1413683&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/TransientDocumentImpl.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/TransientDocumentImpl.java Mon Nov 26 15:30:23 2012
@@ -144,6 +144,10 @@ public class TransientDocumentImpl exten
         return getPropertyValue(PropertyIds.IS_MAJOR_VERSION);
     }
 
+    public Boolean isPrivateWorkingCopy() {
+        return getPropertyValue(PropertyIds.IS_PRIVATE_WORKING_COPY);
+    }
+
     public Boolean isVersionSeriesCheckedOut() {
         return getPropertyValue(PropertyIds.IS_VERSION_SERIES_CHECKED_OUT);
     }

Added: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/objecttype/ItemTypeImpl.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/objecttype/ItemTypeImpl.java?rev=1413683&view=auto
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/objecttype/ItemTypeImpl.java (added)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/objecttype/ItemTypeImpl.java Mon Nov 26 15:30:23 2012
@@ -0,0 +1,62 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.chemistry.opencmis.client.runtime.objecttype;
+
+import java.util.List;
+
+import org.apache.chemistry.opencmis.client.api.ItemIterable;
+import org.apache.chemistry.opencmis.client.api.ItemType;
+import org.apache.chemistry.opencmis.client.api.ObjectType;
+import org.apache.chemistry.opencmis.client.api.Session;
+import org.apache.chemistry.opencmis.client.api.Tree;
+import org.apache.chemistry.opencmis.commons.definitions.ItemTypeDefinition;
+import org.apache.chemistry.opencmis.commons.impl.dataobjects.ItemTypeDefinitionImpl;
+
+public class ItemTypeImpl extends ItemTypeDefinitionImpl implements ItemType {
+
+    private static final long serialVersionUID = 1L;
+
+    private final ObjectTypeHelper helper;
+
+    public ItemTypeImpl(Session session, ItemTypeDefinition typeDefinition) {
+        initialize(typeDefinition);
+        helper = new ObjectTypeHelper(session, this);
+    }
+
+    public ObjectType getBaseType() {
+        return helper.getBaseType();
+    }
+
+    public ItemIterable<ObjectType> getChildren() {
+        return helper.getChildren();
+    }
+
+    public List<Tree<ObjectType>> getDescendants(int depth) {
+        return helper.getDescendants(depth);
+    }
+
+    public ObjectType getParentType() {
+        return helper.getParentType();
+    }
+
+    public boolean isBaseType() {
+        return helper.isBaseType();
+    }
+
+}

Propchange: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/objecttype/ItemTypeImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/objecttype/SecondaryTypeImpl.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/objecttype/SecondaryTypeImpl.java?rev=1413683&view=auto
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/objecttype/SecondaryTypeImpl.java (added)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/objecttype/SecondaryTypeImpl.java Mon Nov 26 15:30:23 2012
@@ -0,0 +1,43 @@
+package org.apache.chemistry.opencmis.client.runtime.objecttype;
+
+import java.util.List;
+
+import org.apache.chemistry.opencmis.client.api.ItemIterable;
+import org.apache.chemistry.opencmis.client.api.ObjectType;
+import org.apache.chemistry.opencmis.client.api.SecondaryType;
+import org.apache.chemistry.opencmis.client.api.Session;
+import org.apache.chemistry.opencmis.client.api.Tree;
+import org.apache.chemistry.opencmis.commons.definitions.SecondaryTypeDefinition;
+import org.apache.chemistry.opencmis.commons.impl.dataobjects.SecondaryTypeDefinitionImpl;
+
+public class SecondaryTypeImpl extends SecondaryTypeDefinitionImpl implements SecondaryType {
+
+    private static final long serialVersionUID = 1L;
+
+    private final ObjectTypeHelper helper;
+
+    public SecondaryTypeImpl(Session session, SecondaryTypeDefinition typeDefinition) {
+        initialize(typeDefinition);
+        helper = new ObjectTypeHelper(session, this);
+    }
+
+    public ObjectType getBaseType() {
+        return helper.getBaseType();
+    }
+
+    public ItemIterable<ObjectType> getChildren() {
+        return helper.getChildren();
+    }
+
+    public List<Tree<ObjectType>> getDescendants(int depth) {
+        return helper.getDescendants(depth);
+    }
+
+    public ObjectType getParentType() {
+        return helper.getParentType();
+    }
+
+    public boolean isBaseType() {
+        return helper.isBaseType();
+    }
+}

Propchange: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/objecttype/SecondaryTypeImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/repository/ObjectFactoryImpl.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/repository/ObjectFactoryImpl.java?rev=1413683&r1=1413682&r2=1413683&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/repository/ObjectFactoryImpl.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/main/java/org/apache/chemistry/opencmis/client/runtime/repository/ObjectFactoryImpl.java Mon Nov 26 15:30:23 2012
@@ -47,6 +47,7 @@ import org.apache.chemistry.opencmis.cli
 import org.apache.chemistry.opencmis.client.runtime.ChangeEventsImpl;
 import org.apache.chemistry.opencmis.client.runtime.DocumentImpl;
 import org.apache.chemistry.opencmis.client.runtime.FolderImpl;
+import org.apache.chemistry.opencmis.client.runtime.ItemImpl;
 import org.apache.chemistry.opencmis.client.runtime.PolicyImpl;
 import org.apache.chemistry.opencmis.client.runtime.PropertyImpl;
 import org.apache.chemistry.opencmis.client.runtime.QueryResultImpl;
@@ -55,8 +56,10 @@ import org.apache.chemistry.opencmis.cli
 import org.apache.chemistry.opencmis.client.runtime.SessionImpl;
 import org.apache.chemistry.opencmis.client.runtime.objecttype.DocumentTypeImpl;
 import org.apache.chemistry.opencmis.client.runtime.objecttype.FolderTypeImpl;
+import org.apache.chemistry.opencmis.client.runtime.objecttype.ItemTypeImpl;
 import org.apache.chemistry.opencmis.client.runtime.objecttype.PolicyTypeImpl;
 import org.apache.chemistry.opencmis.client.runtime.objecttype.RelationshipTypeImpl;
+import org.apache.chemistry.opencmis.client.runtime.objecttype.SecondaryTypeImpl;
 import org.apache.chemistry.opencmis.commons.PropertyIds;
 import org.apache.chemistry.opencmis.commons.data.Ace;
 import org.apache.chemistry.opencmis.commons.data.Acl;
@@ -70,6 +73,7 @@ import org.apache.chemistry.opencmis.com
 import org.apache.chemistry.opencmis.commons.data.RepositoryInfo;
 import org.apache.chemistry.opencmis.commons.definitions.DocumentTypeDefinition;
 import org.apache.chemistry.opencmis.commons.definitions.FolderTypeDefinition;
+import org.apache.chemistry.opencmis.commons.definitions.ItemTypeDefinition;
 import org.apache.chemistry.opencmis.commons.definitions.PolicyTypeDefinition;
 import org.apache.chemistry.opencmis.commons.definitions.PropertyBooleanDefinition;
 import org.apache.chemistry.opencmis.commons.definitions.PropertyDateTimeDefinition;
@@ -81,6 +85,7 @@ import org.apache.chemistry.opencmis.com
 import org.apache.chemistry.opencmis.commons.definitions.PropertyStringDefinition;
 import org.apache.chemistry.opencmis.commons.definitions.PropertyUriDefinition;
 import org.apache.chemistry.opencmis.commons.definitions.RelationshipTypeDefinition;
+import org.apache.chemistry.opencmis.commons.definitions.SecondaryTypeDefinition;
 import org.apache.chemistry.opencmis.commons.definitions.TypeDefinition;
 import org.apache.chemistry.opencmis.commons.enums.Cardinality;
 import org.apache.chemistry.opencmis.commons.enums.ChangeType;
@@ -215,6 +220,10 @@ public class ObjectFactoryImpl implement
             return new RelationshipTypeImpl(this.session, (RelationshipTypeDefinition) typeDefinition);
         } else if (typeDefinition instanceof PolicyTypeDefinition) {
             return new PolicyTypeImpl(this.session, (PolicyTypeDefinition) typeDefinition);
+        } else if (typeDefinition instanceof ItemTypeDefinition) {
+            return new ItemTypeImpl(this.session, (ItemTypeDefinition) typeDefinition);
+        } else if (typeDefinition instanceof SecondaryTypeDefinition) {
+            return new SecondaryTypeImpl(this.session, (SecondaryTypeDefinition) typeDefinition);
         } else if (typeDefinition == null) {
             throw new CmisRuntimeException("No base type supplied!");
         } else {
@@ -496,8 +505,12 @@ public class ObjectFactoryImpl implement
             return new PolicyImpl((SessionImpl) this.session, type, objectData, context);
         case CMIS_RELATIONSHIP:
             return new RelationshipImpl((SessionImpl) this.session, type, objectData, context);
+        case CMIS_ITEM:
+            return new ItemImpl((SessionImpl) this.session, type, objectData, context);
+        case CMIS_SECONDARY:
+            throw new CmisRuntimeException("Secondary type is used as object type: " + objectData.getBaseTypeId());
         default:
-            throw new CmisRuntimeException("unsupported type: " + objectData.getBaseTypeId());
+            throw new CmisRuntimeException("Unsupported base type: " + objectData.getBaseTypeId());
         }
     }
 

Modified: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/test/java/org/apache/chemistry/opencmis/client/runtime/CmisObjectMock.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/test/java/org/apache/chemistry/opencmis/client/runtime/CmisObjectMock.java?rev=1413683&r1=1413682&r2=1413683&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/test/java/org/apache/chemistry/opencmis/client/runtime/CmisObjectMock.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-impl/src/test/java/org/apache/chemistry/opencmis/client/runtime/CmisObjectMock.java Mon Nov 26 15:30:23 2012
@@ -32,6 +32,7 @@ import org.apache.chemistry.opencmis.cli
 import org.apache.chemistry.opencmis.client.api.Property;
 import org.apache.chemistry.opencmis.client.api.Relationship;
 import org.apache.chemistry.opencmis.client.api.Rendition;
+import org.apache.chemistry.opencmis.client.api.SecondaryType;
 import org.apache.chemistry.opencmis.client.api.TransientCmisObject;
 import org.apache.chemistry.opencmis.commons.data.Ace;
 import org.apache.chemistry.opencmis.commons.data.Acl;
@@ -120,6 +121,10 @@ public class CmisObjectMock implements C
         return null;
     }
 
+    public String getDescription() {
+        return null;
+    }
+
     public List<Policy> getPolicies() {
         return null;
     }
@@ -157,6 +162,10 @@ public class CmisObjectMock implements C
         return null;
     }
 
+    public List<SecondaryType> getSecondaryTypes() {
+        return null;
+    }
+
     public List<CmisExtensionElement> getExtensions(ExtensionLevel level) {
         return null;
     }

Modified: chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/PropertyIds.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/PropertyIds.java?rev=1413683&r1=1413682&r2=1413683&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/PropertyIds.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/PropertyIds.java Mon Nov 26 15:30:23 2012
@@ -71,4 +71,13 @@ public final class PropertyIds {
 
     // ---- policy ----
     public static final String POLICY_TEXT = "cmis:policyText";
+
+    // ---- retention ---
+    // CMIS 1.1
+    public static final String EXPIRATION_DATE = "cmis:rm_expirationDate";
+    public static final String START_OF_RETENTION = "cmis:rm_startOfRetention";
+    public static final String DESTRUCTION_DATE = "cmis:rm_destructionDate";
+
+    public static final String HOLD_IDS = "cmis:rm_holdIds";
+
 }

Added: chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/SecondaryTypeIds.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/SecondaryTypeIds.java?rev=1413683&view=auto
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/SecondaryTypeIds.java (added)
+++ chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/SecondaryTypeIds.java Mon Nov 26 15:30:23 2012
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.chemistry.opencmis.commons;
+
+/**
+ * Collection of secondary type ids that are defined in the CMIS specification.
+ */
+public final class SecondaryTypeIds {
+
+    private SecondaryTypeIds() {
+    }
+
+    public static final String REPOSITORY_MANAGED_RETENTION = "cmis:rm_repMgtRetention";
+    public static final String CLIENT_MANAGED_RETENTION = "cmis:rm_clientMgtRetention";
+    public static final String DESTRUCTION_CLIENT_MANAGED_RETENTION = "cmis:rm_destructionRetention.";
+}

Propchange: chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/SecondaryTypeIds.java
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message