/** * Copy this Node and potentially all child nodes to a new parent destination. * * @param destination Node * @param deepCopy True for a deep copy, false otherwise. * * @return The newly copied Node instance or null if failed to copy. */ public ScriptNode copy(ScriptNode destination, boolean deepCopy) { ParameterCheck.mandatory("Destination Node", destination); NodeRef copyRef = this.services.getCopyService().copyAndRename(this.nodeRef, destination.getNodeRef(), ContentModel.ASSOC_CONTAINS, null, deepCopy); ScriptNode copy = newInstance(copyRef, this.services, this.scope); return copy; }
/** * Copy this Node and potentially all child nodes to a new parent destination. * * @param destination Node * @param deepCopy True for a deep copy, false otherwise. * * @return The newly copied Node instance or null if failed to copy. */ public ScriptNode copy(ScriptNode destination, boolean deepCopy) { ParameterCheck.mandatory("Destination Node", destination); NodeRef copyRef = this.services.getCopyService().copyAndRename(this.nodeRef, destination.getNodeRef(), ContentModel.ASSOC_CONTAINS, null, deepCopy); ScriptNode copy = newInstance(copyRef, this.services, this.scope); return copy; }
this.cociService = serviceRegistry.getCheckOutCheckInService(); this.lockService = serviceRegistry.getLockService(); this.copyService = serviceRegistry.getCopyService(); this.contentService = serviceRegistry.getContentService(); this.dictionaryDAO = (DictionaryDAO)applicationContext.getBean("dictionaryDAO");
NodeRef newNodeRef = serviceRegistry.getCopyService().copyAndRename(sourceNodeRef, folderInfo.getNodeRef(), ContentModel.ASSOC_CONTAINS, null, false); fileFolderService.setHidden(newNodeRef, false); messageFile = fileFolderService.getFileInfo(newNodeRef);
NodeRef newNodeRef = serviceRegistry.getCopyService().copyAndRename(sourceNodeRef, folderInfo.getNodeRef(), ContentModel.ASSOC_CONTAINS, null, false); fileFolderService.setHidden(newNodeRef, false); messageFile = fileFolderService.getFileInfo(newNodeRef);
NodeRef copyNodeRef = this.services.getCopyService().copy(this.nodeRef, destination, ContentModel.ASSOC_CONTAINS, QName.createQName(ContentModel.PROP_CONTENT.getNamespaceURI(), QName.createValidLocalName(copyName)),
NodeRef copyNodeRef = this.services.getCopyService().copy(this.nodeRef, destination, ContentModel.ASSOC_CONTAINS, QName.createQName(ContentModel.PROP_CONTENT.getNamespaceURI(), QName.createValidLocalName(copyName)),