Merged CMIS063 to HEAD

Resolve merge issues.

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@17272 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
David Caruana
2009-10-30 22:34:54 +00:00
parent e27a2b6f56
commit 9cafc890c4
10 changed files with 77 additions and 134 deletions

View File

@@ -1,7 +1,7 @@
<model name="cmis:cmismodel" xmlns="http://www.alfresco.org/model/dictionary/1.0">
<description>CMIS Model Definitions</description>
<version>0.62</version>
<version>1.0</version>
<imports>
<import uri="http://www.alfresco.org/model/dictionary/1.0" prefix="d" />
@@ -15,26 +15,17 @@
<data-types>
<data-type name="cmis:id">
<analyser-class>org.alfresco.repo.search.impl.lucene.analysis.AlfrescoStandardAnalyser
</analyser-class>
<analyser-class>org.alfresco.repo.search.impl.lucene.analysis.AlfrescoStandardAnalyser</analyser-class>
<java-class>java.lang.String</java-class>
</data-type>
<data-type name="cmis:uri">
<analyser-class>org.alfresco.repo.search.impl.lucene.analysis.AlfrescoStandardAnalyser
</analyser-class>
<java-class>java.lang.String</java-class>
</data-type>
<data-type name="cmis:xml">
<analyser-class>org.alfresco.repo.search.impl.lucene.analysis.AlfrescoStandardAnalyser
</analyser-class>
<analyser-class>org.alfresco.repo.search.impl.lucene.analysis.AlfrescoStandardAnalyser</analyser-class>
<java-class>java.lang.String</java-class>
</data-type>
<data-type name="cmis:html">
<analyser-class>org.alfresco.repo.search.impl.lucene.analysis.AlfrescoStandardAnalyser
</analyser-class>
<analyser-class>org.alfresco.repo.search.impl.lucene.analysis.AlfrescoStandardAnalyser</analyser-class>
<java-class>java.lang.String</java-class>
</data-type>
@@ -58,7 +49,7 @@
<type name="cmis:object">
<properties>
<property name="cmis:ObjectId">
<property name="cmis:objectId">
<title>Object Id</title>
<description>The unique object id (a node ref)</description>
<type>cmis:id</type>
@@ -69,7 +60,7 @@
<tokenised>false</tokenised>
</index>
</property>
<property name="cmis:ObjectTypeId">
<property name="cmis:objectTypeId">
<title>Object Type Id</title>
<description>Id of the objects type</description>
<type>cmis:id</type>
@@ -80,7 +71,7 @@
<tokenised>false</tokenised>
</index>
</property>
<property name="cmis:BaseTypeId">
<property name="cmis:baseTypeId">
<title>Base Type Id</title>
<description>Id of the base object type for the object</description>
<type>cmis:id</type>
@@ -91,7 +82,7 @@
<tokenised>false</tokenised>
</index>
</property>
<property name="cmis:CreatedBy">
<property name="cmis:createdBy">
<title>Created by</title>
<description>The authority who created this object</description>
<type>d:text</type>
@@ -102,7 +93,7 @@
<tokenised>false</tokenised>
</index>
</property>
<property name="cmis:CreationDate">
<property name="cmis:creationDate">
<title>Creation Date</title>
<description>The object creation date</description>
<type>d:datetime</type>
@@ -113,7 +104,7 @@
<tokenised>false</tokenised>
</index>
</property>
<property name="cmis:LastModifiedBy">
<property name="cmis:lastModifiedBy">
<title>Last Modified By</title>
<description>The authority who last modified this object</description>
<type>d:text</type>
@@ -124,7 +115,7 @@
<tokenised>false</tokenised>
</index>
</property>
<property name="cmis:LastModificationDate">
<property name="cmis:lastModificationDate">
<title>Last Modified Date</title>
<description>The date this object was last modified</description>
<type>d:datetime</type>
@@ -135,7 +126,7 @@
<tokenised>false</tokenised>
</index>
</property>
<property name="cmis:ChangeToken">
<property name="cmis:changeToken">
<title>Change token</title>
<description>Change Token</description>
<type>d:text</type>
@@ -151,7 +142,7 @@
<type name="cmis:filesystemobject">
<parent>cmis:object</parent>
<properties>
<property name="cmis:Name">
<property name="cmis:name">
<title>Name</title>
<description>Name</description>
<type>d:text</type>
@@ -170,7 +161,7 @@
<description>Document Type</description>
<parent>cmis:filesystemobject</parent>
<properties>
<property name="cmis:IsImmutable">
<property name="cmis:isImmutable">
<title>Is Immutable</title>
<description>Is the document immutable?</description>
<type>d:boolean</type>
@@ -179,7 +170,7 @@
<multiple>false</multiple>
<index enabled="false" />
</property>
<property name="cmis:IsLatestVersion">
<property name="cmis:isLatestVersion">
<title>Is Latest Version</title>
<description>Is this the latest version of the document?</description>
<type>d:boolean</type>
@@ -188,7 +179,7 @@
<multiple>false</multiple>
<index enabled="false" />
</property>
<property name="cmis:IsMajorVersion">
<property name="cmis:isMajorVersion">
<title>Is Major Version</title>
<description>Is this a major version of the document?</description>
<type>d:boolean</type>
@@ -197,7 +188,7 @@
<multiple>false</multiple>
<index enabled="false" />
</property>
<property name="cmis:IsLatestMajorVersion">
<property name="cmis:isLatestMajorVersion">
<title>Is Latest Major Version</title>
<description>Is this the latest major version of the document?</description>
<type>d:boolean</type>
@@ -206,7 +197,7 @@
<multiple>false</multiple>
<index enabled="false" />
</property>
<property name="cmis:VersionLabel">
<property name="cmis:versionLabel">
<title>Version Label</title>
<description>The version label</description>
<type>d:text</type>
@@ -217,7 +208,7 @@
<tokenised>true</tokenised>
</index>
</property>
<property name="cmis:VersionSeriesId">
<property name="cmis:versionSeriesId">
<title>Version series id</title>
<description>The version series id</description>
<type>cmis:id</type>
@@ -228,7 +219,7 @@
<tokenised>false</tokenised>
</index>
</property>
<property name="cmis:IsVersionSeriesCheckedOut">
<property name="cmis:isVersionSeriesCheckedOut">
<title>Is Version Series Checked Out</title>
<description>Is the version series checked out?</description>
<type>d:boolean</type>
@@ -237,7 +228,7 @@
<multiple>false</multiple>
<index enabled="false" />
</property>
<property name="cmis:VersionSeriesCheckedOutBy">
<property name="cmis:versionSeriesCheckedOutBy">
<title>Version Series Checked Out By</title>
<description>The authority who checked out this document version series</description>
<type>d:text</type>
@@ -246,7 +237,7 @@
<multiple>false</multiple>
<index enabled="false" />
</property>
<property name="cmis:VersionSeriesCheckedOutId">
<property name="cmis:versionSeriesCheckedOutId">
<title>Version Series Checked Out Id</title>
<description>The checked out version series id</description>
<type>cmis:id</type>
@@ -255,7 +246,7 @@
<multiple>false</multiple>
<index enabled="false" />
</property>
<property name="cmis:CheckinComment">
<property name="cmis:checkinComment">
<title>Checkin Comment</title>
<description>The checkin comment</description>
<type>d:text</type>
@@ -264,7 +255,7 @@
<multiple>false</multiple>
<index enabled="false" />
</property>
<property name="cmis:ContentStreamLength">
<property name="cmis:contentStreamLength">
<title>Content Stream Length</title>
<description>The length of the content stream</description>
<type>d:int</type>
@@ -275,7 +266,7 @@
<tokenised>false</tokenised>
</index>
</property>
<property name="cmis:ContentStreamMimeType">
<property name="cmis:contentStreamMimeType">
<title>Content Stream MIME Type</title>
<description>The content stream MIME type</description>
<type>d:text</type>
@@ -286,7 +277,7 @@
<tokenised>false</tokenised>
</index>
</property>
<property name="cmis:ContentStreamFileName">
<property name="cmis:contentStreamFileName">
<title>Content Stream Filename</title>
<description>The content stream filename</description>
<type>d:text</type>
@@ -297,7 +288,7 @@
<tokenised>true</tokenised>
</index>
</property>
<property name="cmis:ContentStreamId">
<property name="cmis:contentStreamId">
<title>Content Stream Id</title>
<description>Id of the stream</description>
<type>cmis:id</type>
@@ -316,7 +307,7 @@
<description>Folder Type</description>
<parent>cmis:filesystemobject</parent>
<properties>
<property name="cmis:ParentId">
<property name="cmis:parentId">
<title>Parent Id</title>
<description>The parent id of the folder</description>
<type>cmis:id</type>
@@ -327,9 +318,9 @@
<tokenised>false</tokenised>
</index>
</property>
<property name="cmis:PathName">
<title>Path Name</title>
<description>Name of the path element for this folder</description>
<property name="cmis:path">
<title>Path</title>
<description>The fully qualified path to this folder/description</description>
<type>d:text</type>
<protected>true</protected>
<mandatory enforced="true">true</mandatory>
@@ -338,7 +329,7 @@
<tokenised>false</tokenised>
</index>
</property>
<property name="cmis:AllowedChildObjectTypeIds">
<property name="cmis:allowedChildObjectTypeIds">
<title>Allowed Child Object Types Ids</title>
<description>The allowed child object type ids</description>
<type>cmis:id</type>
@@ -355,7 +346,7 @@
<description>Relationship Type</description>
<parent>cmis:object</parent>
<properties>
<property name="cmis:SourceId">
<property name="cmis:sourceId">
<title>Source Id</title>
<description>The source id for the relationship</description>
<type>cmis:id</type>
@@ -364,7 +355,7 @@
<multiple>false</multiple>
<index enabled="false" />
</property>
<property name="cmis:TargetId">
<property name="cmis:targetId">
<title>Target Id</title>
<description>The target id for the relationship</description>
<type>cmis:id</type>
@@ -381,7 +372,7 @@
<description>Policy Type</description>
<parent>cmis:object</parent>
<properties>
<property name="cmis:PolicyText">
<property name="cmis:policyText">
<title>Policy Text</title>
<description>The policy text</description>
<type>d:text</type>

View File

@@ -32,7 +32,8 @@ package org.alfresco.cmis;
public enum CMISAllowedActionEnum implements EnumLabel
{
// navigation services
CAN_GET_DESCENDANTS("canGetDescendants"),
CAN_GET_DESCENDANTS("canGetDescendants"),
CAN_GET_FOLDER_TREE("canGetFolderTree"),
CAN_GET_CHILDREN("canGetChildren"),
CAN_GET_FOLDER_PARENT("canGetFolderParent"),
CAN_GET_OBJECT_PARENTS("canGetObjectParents"),
@@ -48,7 +49,6 @@ public enum CMISAllowedActionEnum implements EnumLabel
CAN_UPDATE_PROPERTIES("canUpdateProperties"),
CAN_MOVE_OBJECT("canMoveObject"),
CAN_DELETE_OBJECT("canDeleteObject"),
CAN_DELETE_TREE("canDeleteTree"),
CAN_SET_CONTENT_STREAM("canSetContentStream"),
CAN_DELETE_CONTENT_STREAM("canDeleteContentStream"),
@@ -63,7 +63,7 @@ public enum CMISAllowedActionEnum implements EnumLabel
CAN_GET_ALL_VERSIONS("canGetAllVersions"),
// relationship services
CAN_GET_RELATIONSHIPS("canGetRelationships"),
CAN_GET_OBJECT_RELATIONSHIPS("canGetObjectRelationships"),
// policy services
CAN_APPLY_POLICY("canApplyPolicy"),

View File

@@ -83,13 +83,6 @@ public enum CMISDataTypeEnum implements EnumLabel
return DataTypeDefinition.TEXT;
}
},
XML("xml")
{
public QName getDefaultDataType()
{
return DataTypeDefinition.TEXT;
}
},
HTML("html")
{
public QName getDefaultDataType()

View File

@@ -41,34 +41,34 @@ public interface CMISDictionaryModel
public static CMISTypeId POLICY_TYPE_ID = new CMISTypeId(CMISScope.POLICY, CMISMapping.POLICY_QNAME, CMISMapping.CMIS_MODEL_NS + ":" + CMISMapping.POLICY_QNAME.getLocalName(), CMISMapping.POLICY_QNAME);
// CMIS properties
public static String PROP_OBJECT_ID = "cmis:ObjectId";
public static String PROP_BASE_TYPE_ID = "cmis:BaseTypeId";
public static String PROP_OBJECT_TYPE_ID = "cmis:ObjectTypeId";
public static String PROP_CREATED_BY = "cmis:CreatedBy";
public static String PROP_CREATION_DATE = "cmis:CreationDate";
public static String PROP_LAST_MODIFIED_BY = "cmis:LastModifiedBy";
public static String PROP_LAST_MODIFICATION_DATE = "cmis:LastModificationDate";
public static String PROP_CHANGE_TOKEN = "cmis:ChangeToken";
public static String PROP_NAME = "cmis:Name";
public static String PROP_IS_IMMUTABLE = "cmis:IsImmutable";
public static String PROP_IS_LATEST_VERSION = "cmis:IsLatestVersion";
public static String PROP_IS_MAJOR_VERSION = "cmis:IsMajorVersion";
public static String PROP_IS_LATEST_MAJOR_VERSION = "cmis:IsLatestMajorVersion";
public static String PROP_VERSION_LABEL = "cmis:VersionLabel";
public static String PROP_VERSION_SERIES_ID = "cmis:VersionSeriesId";
public static String PROP_IS_VERSION_SERIES_CHECKED_OUT = "cmis:IsVersionSeriesCheckedOut";
public static String PROP_VERSION_SERIES_CHECKED_OUT_BY = "cmis:VersionSeriesCheckedOutBy";
public static String PROP_VERSION_SERIES_CHECKED_OUT_ID = "cmis:VersionSeriesCheckedOutId";
public static String PROP_CHECKIN_COMMENT = "cmis:CheckinComment";
public static String PROP_CONTENT_STREAM_LENGTH = "cmis:ContentStreamLength";
public static String PROP_CONTENT_STREAM_MIME_TYPE = "cmis:ContentStreamMimeType";
public static String PROP_CONTENT_STREAM_FILENAME = "cmis:ContentStreamFileName";
public static String PROP_CONTENT_STREAM_ID = "cmis:ContentStreamId";
public static String PROP_PARENT_ID = "cmis:ParentId";
public static String PROP_PATH_NAME = "cmis:PathName";
public static String PROP_ALLOWED_CHILD_OBJECT_TYPE_IDS = "cmis:AllowedChildObjectTypeIds";
public static String PROP_SOURCE_ID = "cmis:SourceId";
public static String PROP_TARGET_ID = "cmis:TargetId";
public static String PROP_POLICY_TEXT = "cmis:PolicyText";
public static String PROP_OBJECT_ID = "cmis:objectId";
public static String PROP_BASE_TYPE_ID = "cmis:baseTypeId";
public static String PROP_OBJECT_TYPE_ID = "cmis:objectTypeId";
public static String PROP_CREATED_BY = "cmis:createdBy";
public static String PROP_CREATION_DATE = "cmis:creationDate";
public static String PROP_LAST_MODIFIED_BY = "cmis:lastModifiedBy";
public static String PROP_LAST_MODIFICATION_DATE = "cmis:lastModificationDate";
public static String PROP_CHANGE_TOKEN = "cmis:changeToken";
public static String PROP_NAME = "cmis:name";
public static String PROP_IS_IMMUTABLE = "cmis:isImmutable";
public static String PROP_IS_LATEST_VERSION = "cmis:isLatestVersion";
public static String PROP_IS_MAJOR_VERSION = "cmis:isMajorVersion";
public static String PROP_IS_LATEST_MAJOR_VERSION = "cmis:isLatestMajorVersion";
public static String PROP_VERSION_LABEL = "cmis:versionLabel";
public static String PROP_VERSION_SERIES_ID = "cmis:versionSeriesId";
public static String PROP_IS_VERSION_SERIES_CHECKED_OUT = "cmis:isVersionSeriesCheckedOut";
public static String PROP_VERSION_SERIES_CHECKED_OUT_BY = "cmis:versionSeriesCheckedOutBy";
public static String PROP_VERSION_SERIES_CHECKED_OUT_ID = "cmis:versionSeriesCheckedOutId";
public static String PROP_CHECKIN_COMMENT = "cmis:checkinComment";
public static String PROP_CONTENT_STREAM_LENGTH = "cmis:contentStreamLength";
public static String PROP_CONTENT_STREAM_MIME_TYPE = "cmis:contentStreamMimeType";
public static String PROP_CONTENT_STREAM_FILENAME = "cmis:contentStreamFileName";
public static String PROP_CONTENT_STREAM_ID = "cmis:contentStreamId";
public static String PROP_PARENT_ID = "cmis:parentId";
public static String PROP_PATH = "cmis:path";
public static String PROP_ALLOWED_CHILD_OBJECT_TYPE_IDS = "cmis:allowedChildObjectTypeIds";
public static String PROP_SOURCE_ID = "cmis:sourceId";
public static String PROP_TARGET_ID = "cmis:targetId";
public static String PROP_POLICY_TEXT = "cmis:policyText";
}

View File

@@ -138,20 +138,6 @@ public interface CMISPropertyDefinition
*/
public int getMaximumLength();
/**
* For properties of type CMISPropertyType.XML the schema to which the property must conform. Unsupported
*
* @return - the schema URI
*/
public String getSchemaURI();
/**
* For properties of type CMISPropertyType.XML the encoding used for the property value
*
* @return the encoding
*/
public String getEncoding();
/**
* Gets the property accessor (for reading / writing values)
*

View File

@@ -71,8 +71,6 @@ public class CMISBasePropertyDefinition implements CMISPropertyDefinition, Seria
private CMISDataTypeEnum propertyType;
private CMISCardinalityEnum cardinality;
private int maximumLength = -1;
private String schemaURI = null;
private String encoding = null;
private Collection<CMISChoice> choices = new HashSet<CMISChoice>();
private boolean isOpenChoice = false;
private boolean required;
@@ -239,26 +237,6 @@ public class CMISBasePropertyDefinition implements CMISPropertyDefinition, Seria
return maximumLength;
}
/**
* For properties of type CMISPropertyType.XML the schema to which the property must conform. Unsupported
*
* @return - the schema URI
*/
public String getSchemaURI()
{
return schemaURI;
}
/**
* For properties of type CMISPropertyType.XML the encoding used for the property value
*
* @return the encoding
*/
public String getEncoding()
{
return encoding;
}
/**
* Get the choices available as values for this property TODO: not implemented yet
*
@@ -370,8 +348,6 @@ public class CMISBasePropertyDefinition implements CMISPropertyDefinition, Seria
builder.append("PropertyType=").append(getDataType()).append(", ");
builder.append("Cardinality=").append(getCardinality()).append(", ");
builder.append("MaximumLength=").append(getMaximumLength()).append(", ");
builder.append("SchemaURI=").append(getSchemaURI()).append(", ");
builder.append("Encoding=").append(getEncoding()).append(", ");
builder.append("Choices=").append(getChoices()).append(", ");
builder.append("IsOpenChoice=").append(isOpenChoice()).append(", ");
builder.append("Required=").append(isRequired()).append(", ");

View File

@@ -158,7 +158,6 @@ public class CMISMapping implements InitializingBean
mapAlfrescoToCmisDataType.put(DataTypeDefinition.TEXT, CMISDataTypeEnum.STRING);
mapAlfrescoToCmisDataType.put(CMIS_DATATYPE_ID, CMISDataTypeEnum.ID);
mapAlfrescoToCmisDataType.put(CMIS_DATATYPE_URI, CMISDataTypeEnum.URI);
mapAlfrescoToCmisDataType.put(CMIS_DATATYPE_XML, CMISDataTypeEnum.XML);
mapAlfrescoToCmisDataType.put(CMIS_DATATYPE_HTML, CMISDataTypeEnum.HTML);
//
@@ -189,7 +188,7 @@ public class CMISMapping implements InitializingBean
registerPropertyAccessor(new ContentStreamIdProperty(serviceRegistry));
registerPropertyAccessor(new DirectProperty(serviceRegistry, CMISDictionaryModel.PROP_CONTENT_STREAM_FILENAME, ContentModel.PROP_NAME));
registerPropertyAccessor(new ParentProperty(serviceRegistry));
registerPropertyAccessor(new PathNameProperty(serviceRegistry, cmisService));
registerPropertyAccessor(new PathProperty(serviceRegistry, cmisService));
registerPropertyAccessor(new FixedValueProperty(serviceRegistry, CMISDictionaryModel.PROP_ALLOWED_CHILD_OBJECT_TYPE_IDS, null));
registerPropertyAccessor(new SourceIdProperty(serviceRegistry));
registerPropertyAccessor(new TargetIdProperty(serviceRegistry));
@@ -201,7 +200,7 @@ public class CMISMapping implements InitializingBean
registerEvaluator(CMISScope.DOCUMENT, new PermissionActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_DELETE_OBJECT, PermissionService.DELETE_NODE));
registerEvaluator(CMISScope.DOCUMENT, new PermissionActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_UPDATE_PROPERTIES, PermissionService.WRITE_PROPERTIES));
registerEvaluator(CMISScope.DOCUMENT, new PermissionActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_PROPERTIES, PermissionService.READ_PROPERTIES));
registerEvaluator(CMISScope.DOCUMENT, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_RELATIONSHIPS, true));
registerEvaluator(CMISScope.DOCUMENT, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_OBJECT_RELATIONSHIPS, true));
registerEvaluator(CMISScope.DOCUMENT, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_OBJECT_PARENTS, true));
// Is CAN_MOVE correct mapping?
registerEvaluator(CMISScope.DOCUMENT, new PermissionActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_MOVE_OBJECT, PermissionService.DELETE_NODE));
@@ -227,7 +226,7 @@ public class CMISMapping implements InitializingBean
registerEvaluator(CMISScope.FOLDER, new PermissionActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_UPDATE_PROPERTIES, PermissionService.WRITE_PROPERTIES));
registerEvaluator(CMISScope.FOLDER, new PermissionActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_FOLDER_TREE, PermissionService.READ_CHILDREN));
registerEvaluator(CMISScope.FOLDER, new PermissionActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_PROPERTIES, PermissionService.READ_PROPERTIES));
registerEvaluator(CMISScope.FOLDER, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_RELATIONSHIPS, true));
registerEvaluator(CMISScope.FOLDER, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_OBJECT_RELATIONSHIPS, true));
registerEvaluator(CMISScope.FOLDER, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_OBJECT_PARENTS, true));
registerEvaluator(CMISScope.FOLDER, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_FOLDER_PARENT, true));
registerEvaluator(CMISScope.FOLDER, new PermissionActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_DESCENDANTS, PermissionService.READ_CHILDREN));
@@ -241,7 +240,6 @@ public class CMISMapping implements InitializingBean
registerEvaluator(CMISScope.FOLDER, new PermissionActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_CREATE_FOLDER, PermissionService.CREATE_CHILDREN));
registerEvaluator(CMISScope.FOLDER, new PermissionActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_CREATE_RELATIONSHIP, PermissionService.CREATE_ASSOCIATIONS));
registerEvaluator(CMISScope.FOLDER, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_CREATE_POLICY, false));
registerEvaluator(CMISScope.FOLDER, new PermissionActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_DELETE_TREE, PermissionService.DELETE_NODE));
registerEvaluator(CMISScope.FOLDER, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_ACL, false));
registerEvaluator(CMISScope.FOLDER, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_APPLY_ACL, false));
@@ -258,7 +256,7 @@ public class CMISMapping implements InitializingBean
registerEvaluator(CMISScope.POLICY, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_MOVE_OBJECT, false));
registerEvaluator(CMISScope.POLICY, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_ADD_OBJECT_TO_FOLDER, false));
registerEvaluator(CMISScope.POLICY, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_REMOVE_OBJECT_FROM_FOLDER, false));
registerEvaluator(CMISScope.POLICY, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_RELATIONSHIPS, false));
registerEvaluator(CMISScope.POLICY, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_OBJECT_RELATIONSHIPS, false));
registerEvaluator(CMISScope.POLICY, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_GET_ACL, false));
registerEvaluator(CMISScope.POLICY, new FixedValueActionEvaluator(serviceRegistry, CMISAllowedActionEnum.CAN_APPLY_ACL, false));
}

View File

@@ -44,7 +44,7 @@ public class CMISPropertyServiceTest extends BaseCMISTest
{
public void testBasicFolder()
{
NodeRef folder = fileFolderService.create(rootNodeRef, "BaseFolder", ContentModel.TYPE_FOLDER).getNodeRef();
NodeRef folder = fileFolderService.create(cmisService.getDefaultRootNodeRef(), "BaseFolder", ContentModel.TYPE_FOLDER).getNodeRef();
Map<String, Serializable> properties = cmisService.getProperties(folder);
assertEquals(folder.toString(), properties.get(CMISDictionaryModel.PROP_OBJECT_ID));
assertEquals(CMISDictionaryModel.FOLDER_TYPE_ID.getId(), properties.get(CMISDictionaryModel.PROP_OBJECT_TYPE_ID));
@@ -72,7 +72,7 @@ public class CMISPropertyServiceTest extends BaseCMISTest
assertNull(properties.get(CMISDictionaryModel.PROP_CONTENT_STREAM_FILENAME));
assertNull(properties.get(CMISDictionaryModel.PROP_CONTENT_STREAM_ID));
assertEquals(rootNodeRef.toString(), properties.get(CMISDictionaryModel.PROP_PARENT_ID));
assertEquals(cmisService.getDefaultRootNodeRef().toString(), properties.get(CMISDictionaryModel.PROP_PARENT_ID));
assertNull(properties.get(CMISDictionaryModel.PROP_ALLOWED_CHILD_OBJECT_TYPE_IDS));
}

View File

@@ -37,11 +37,11 @@ import org.alfresco.service.cmr.repository.Path;
import org.alfresco.service.cmr.repository.Path.ChildAssocElement;
/**
* Get the CMIS object id property.
* Get the CMIS path property.
*
* @author davidc
*/
public class PathNameProperty extends AbstractProperty
public class PathProperty extends AbstractProperty
{
private CMISServices cmisService;
@@ -50,9 +50,9 @@ public class PathNameProperty extends AbstractProperty
*
* @param serviceRegistry
*/
public PathNameProperty(ServiceRegistry serviceRegistry, CMISServices cmisService)
public PathProperty(ServiceRegistry serviceRegistry, CMISServices cmisService)
{
super(serviceRegistry, CMISDictionaryModel.PROP_PATH_NAME);
super(serviceRegistry, CMISDictionaryModel.PROP_PATH);
this.cmisService = cmisService;
}

View File

@@ -31,7 +31,6 @@ import java.util.Map;
import org.alfresco.cmis.CMISDictionaryModel;
import org.alfresco.cmis.CMISDictionaryService;
import org.alfresco.cmis.CMISPropertyDefinition;
import org.alfresco.cmis.mapping.CMISMapping;
import org.alfresco.repo.search.impl.lucene.LuceneFunction;
import org.alfresco.repo.search.impl.lucene.LuceneQueryParser;
import org.alfresco.repo.search.impl.querymodel.FunctionArgument;