mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-14 17:58:59 +00:00
Merged RETURN-OF-THE-API (5.2.0) to 5.2.N (5.2.1)
128442 jvonka: V1 REST API: Update binary content - add optional name param (to allow rename on upload of a new version) - api implementation + api sanity tests (+ve/-ve) REPO-518 git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/DEV/5.2.N/root@129159 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -87,6 +87,14 @@ public class NodesEntityResource implements
|
||||
return nodes.getFolderOrDocument(nodeId, parameters);
|
||||
}
|
||||
|
||||
/**
|
||||
* Download content
|
||||
*
|
||||
* @param fileNodeId
|
||||
* @param parameters {@link Parameters}
|
||||
* @return
|
||||
* @throws EntityNotFoundException
|
||||
*/
|
||||
@Override
|
||||
@WebApiDescription(title = "Download content", description = "Download content")
|
||||
@BinaryProperties({"content"})
|
||||
@@ -95,6 +103,19 @@ public class NodesEntityResource implements
|
||||
return nodes.getContent(fileNodeId, parameters, true);
|
||||
}
|
||||
|
||||
/**
|
||||
* Upload new version of content
|
||||
*
|
||||
* This allow binary content update of an existing file/content node.
|
||||
*
|
||||
* Note: alternatively, can upload via POST (multipart/form-data) with existing file name and form "overwrite=true".
|
||||
*
|
||||
* @param fileNodeId
|
||||
* @param contentInfo Basic information about the content stream
|
||||
* @param stream An inputstream
|
||||
* @param parameters
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
@WebApiDescription(title = "Upload content", description = "Upload content")
|
||||
@BinaryProperties({"content"})
|
||||
|
Reference in New Issue
Block a user