MOB-378 (AtomPub binding) Support for sub-types (and properties)

- 1st pass at creation of document / folder sub-types
- 1st pass at setting / updating custom properties
- Existing AtomPub CMIS Tests passing

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@13707 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
David Caruana
2009-03-22 15:23:53 +00:00
parent 3f78bf9b32
commit 384f4abdf9
25 changed files with 417 additions and 272 deletions

View File

@@ -32,6 +32,7 @@ import org.alfresco.cmis.dictionary.CMISMapping;
import org.alfresco.cmis.dictionary.CMISScope;
import org.alfresco.repo.search.impl.lucene.LuceneQueryParser;
import org.alfresco.repo.search.impl.querymodel.PredicateMode;
import org.alfresco.service.ServiceRegistry;
import org.alfresco.service.cmr.dictionary.DataTypeDefinition;
import org.alfresco.service.cmr.repository.ChildAssociationRef;
import org.alfresco.service.cmr.repository.NodeRef;
@@ -53,17 +54,13 @@ import org.apache.lucene.search.BooleanClause.Occur;
public class ParentPropertyAccessor extends AbstractNamedPropertyAccessor
{
private CMISService cmisService;
/**
* @param cmisService
*/
public void setCMISService(CMISService cmisService)
protected ParentPropertyAccessor(CMISMapping cmisMapping, ServiceRegistry serviceRegistry, CMISService cmisService)
{
super(cmisMapping, serviceRegistry, CMISScope.FOLDER, CMISMapping.PROP_PARENT_ID);
this.cmisService = cmisService;
}
public Serializable getProperty(NodeRef nodeRef)
{
if (nodeRef.equals(cmisService.getDefaultRootNodeRef()))
@@ -82,20 +79,11 @@ public class ParentPropertyAccessor extends AbstractNamedPropertyAccessor
}
}
@Override
public String getPropertyName()
public void setProperty(NodeRef nodeRef, Serializable value)
{
return CMISMapping.PROP_PARENT_ID;
throw new UnsupportedOperationException();
}
@Override
public CMISScope getScope()
{
return CMISScope.FOLDER;
}
private String getLuceneFieldName()
{
return "PARENT";