06-13-2010 06:11 AM
NodeService ns = getNodeService();
// get the Space to apply changes too
NodeRef nodeRef = this.getNode().getNodeRef();
// Folder this doc belongs to.
NodeRef docFolder = ns.getPrimaryParent(nodeRef).getParentRef();
// Get ebns - parent folder to docFolder.
NodeRef ebns = ns.getPrimaryParent(docFolder).getParentRef();
// Find destination folder within ebns.
NodeRef destNodeRef = this.getFileFolderService().searchSimple(ebns, "nextFolderName");
// Move the node.
try {
getFileFolderService().move(nodeRef, destNodeRef, "some new name");
} catch (FileExistsException e) {
e.printStackTrace();
} catch (FileNotFoundException e) {
e.printStackTrace();
}
The node's content is missing:
node: workspace://SpacesStore/e16ed62d-36b7-45ef-93c2-b19eafffc1e6
reader: null
Please contact your system administrator.
06-13-2010 11:21 PM
Map<QName, Serializable> properties = new HashMap<QName, Serializable>();
this.getNodeService().setProperties(this.getNode().getNodeRef(), properties);
Map<QName, Serializable> properties = getNodeService().getProperties(nodeRef);
this.getNodeService().setProperties(this.getNode().getNodeRef(), properties);
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.