mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Merged CMIS063 to HEAD
17100: Chemistry: AtomPub TCK updates, Alfresco CMIS URL bindings, Delete Content Stream git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@17258 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -116,6 +116,7 @@ public class CMISServicesImpl implements CMISServices, ApplicationContextAware,
|
||||
private String cmisVersion = "[undefined]";
|
||||
|
||||
// default CMIS store and path
|
||||
private StoreRef defaultStoreRef;
|
||||
private String defaultRootPath;
|
||||
private Map<String, NodeRef> defaultRootNodeRefs;
|
||||
|
||||
@@ -134,12 +135,20 @@ public class CMISServicesImpl implements CMISServices, ApplicationContextAware,
|
||||
this.cmisVersion = cmisVersion;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the default root store
|
||||
*
|
||||
* @param store store_type://store_id
|
||||
*/
|
||||
public void setDefaultStore(String store)
|
||||
{
|
||||
this.defaultStoreRef = new StoreRef(store);
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the default root path
|
||||
*
|
||||
* store_type/store_id/path...
|
||||
*
|
||||
* @param path store_type/store_id/path...
|
||||
* @param path path within default store
|
||||
*/
|
||||
public void setDefaultRootPath(String path)
|
||||
{
|
||||
@@ -312,8 +321,9 @@ public class CMISServicesImpl implements CMISServices, ApplicationContextAware,
|
||||
return retryingTransactionHelper.doInTransaction(new RetryingTransactionCallback<NodeRef>()
|
||||
{
|
||||
public NodeRef execute() throws Exception
|
||||
{
|
||||
return repository.findNodeRef("path", defaultRootPath.split("/"));
|
||||
{
|
||||
String path = defaultStoreRef.getProtocol() + "/" + defaultStoreRef.getIdentifier() + defaultRootPath;
|
||||
return repository.findNodeRef("path", path.split("/"));
|
||||
};
|
||||
});
|
||||
}
|
||||
@@ -337,6 +347,16 @@ public class CMISServicesImpl implements CMISServices, ApplicationContextAware,
|
||||
return getDefaultRootNodeRef().getStoreRef();
|
||||
}
|
||||
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.alfresco.cmis.CMISServices#getNode(java.lang.String, java.lang.String[])
|
||||
*/
|
||||
public NodeRef getNode(String referenceType, String[] reference)
|
||||
{
|
||||
NodeRef nodeRef = repository.findNodeRef(referenceType, reference);
|
||||
return nodeRef;
|
||||
}
|
||||
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.alfresco.cmis.CMISServices#getChildren(org.alfresco.service.cmr.repository.NodeRef, org.alfresco.cmis.CMISTypesFilterEnum)
|
||||
|
Reference in New Issue
Block a user