private void doLeave( AbstractJcrNode targetNode ) throws RepositoryException { if (!isShallow) { for (NodeIterator iter = targetNode.getNodesInternal(); iter.hasNext();) { doMerge((AbstractJcrNode)iter.nextNode()); } } }
private void doLeave( AbstractJcrNode targetNode ) throws RepositoryException { if (!isShallow) { for (NodeIterator iter = targetNode.getNodesInternal(); iter.hasNext();) { doMerge((AbstractJcrNode)iter.nextNode()); } } }
protected NodeIterator getNodesInternal( String namePattern ) throws RepositoryException { CheckArg.isNotNull(namePattern, "namePattern"); checkSession(); if (namePattern.length() == 0) return JcrEmptyNodeIterator.INSTANCE; if ("*".equals(namePattern)) return getNodesInternal(); return getNodesInternal(patternStringToGlobArray(namePattern)); }
protected NodeIterator getNodesInternal( String namePattern ) throws RepositoryException { CheckArg.isNotNull(namePattern, "namePattern"); checkSession(); if (namePattern.length() == 0) return JcrEmptyNodeIterator.INSTANCE; if ("*".equals(namePattern)) return getNodesInternal(); return getNodesInternal(patternStringToGlobArray(namePattern)); }
/** * Finds the top nodes which have been created during the sequencing process, based on the original output node. It is * important that this is called before the session is saved, because it uses the new flag. * * @param rootOutputNode the node under which the output of the sequencing process was written to. * @return the first level of output nodes that were created during the sequencing process; never null * @throws RepositoryException if there is a problem finding the output nodes */ private List<AbstractJcrNode> findOutputNodes( AbstractJcrNode rootOutputNode ) throws RepositoryException { if (rootOutputNode.isNew()) { return Arrays.asList(rootOutputNode); } // if the node was not new, we need to find the new sequenced nodes List<AbstractJcrNode> nodes = new ArrayList<AbstractJcrNode>(); NodeIterator childrenIt = rootOutputNode.getNodesInternal(); while (childrenIt.hasNext()) { Node child = childrenIt.nextNode(); if (child.isNew()) { nodes.add((AbstractJcrNode)child); } } return nodes; }
/** * Finds the top nodes which have been created during the sequencing process, based on the original output node. It is * important that this is called before the session is saved, because it uses the new flag. * * @param rootOutputNode the node under which the output of the sequencing process was written to. * @return the first level of output nodes that were created during the sequencing process; never null * @throws RepositoryException if there is a problem finding the output nodes */ private List<AbstractJcrNode> findOutputNodes( AbstractJcrNode rootOutputNode ) throws RepositoryException { if (rootOutputNode.isNew()) { return Arrays.asList(rootOutputNode); } // if the node was not new, we need to find the new sequenced nodes List<AbstractJcrNode> nodes = new ArrayList<AbstractJcrNode>(); NodeIterator childrenIt = rootOutputNode.getNodesInternal(); while (childrenIt.hasNext()) { Node child = childrenIt.nextNode(); if (child.isNew()) { nodes.add((AbstractJcrNode)child); } } return nodes; }
LOGGER.trace("Looking under '{0}' for existing output to be removed for {1}", parentOfOutput.getPath(), logMsg); NodeIterator outputIter = parentOfOutput.getNodesInternal(outputNodeName); while (outputIter.hasNext()) { Node outputNode = outputIter.nextNode();
LOGGER.trace("Looking under '{0}' for existing output to be removed for {1}", parentOfOutput.getPath(), logMsg); NodeIterator outputIter = parentOfOutput.getNodesInternal(outputNodeName); while (outputIter.hasNext()) { Node outputNode = outputIter.nextNode();
Set<AbstractJcrNode> sourceNodesPresentInBoth = new LinkedHashSet<AbstractJcrNode>(); for (NodeIterator iter = targetNode.getNodesInternal(); iter.hasNext();) { AbstractJcrNode targetChild = (AbstractJcrNode)iter.nextNode(); try { for (NodeIterator iter = sourceNode.getNodesInternal(); iter.hasNext();) { AbstractJcrNode sourceChild = (AbstractJcrNode)iter.nextNode(); if (!sourceNodesPresentInBoth.contains(sourceChild)) {
Set<AbstractJcrNode> sourceNodesPresentInBoth = new LinkedHashSet<AbstractJcrNode>(); for (NodeIterator iter = targetNode.getNodesInternal(); iter.hasNext();) { AbstractJcrNode targetChild = (AbstractJcrNode)iter.nextNode(); try { for (NodeIterator iter = sourceNode.getNodesInternal(); iter.hasNext();) { AbstractJcrNode sourceChild = (AbstractJcrNode)iter.nextNode(); if (!sourceNodesPresentInBoth.contains(sourceChild)) {
for (NodeIterator iter = targetNode.getNodesInternal(); iter.hasNext();) { AbstractJcrNode childNode = (AbstractJcrNode)iter.nextNode();
for (NodeIterator iter = targetNode.getNodesInternal(); iter.hasNext();) { AbstractJcrNode childNode = (AbstractJcrNode)iter.nextNode();
NodeIterator nodeIterator = node.getNodesInternal(); while (nodeIterator.hasNext()) { removeHistories((AbstractJcrNode)nodeIterator.nextNode(), systemSession);
NodeIterator nodeIterator = node.getNodesInternal(); while (nodeIterator.hasNext()) { removeHistories((AbstractJcrNode)nodeIterator.nextNode(), systemSession);
for (NodeIterator iter = getNodesInternal(); iter.hasNext();) { AbstractJcrNode child = (AbstractJcrNode)iter.nextNode(); NodeDefinition childDefinition = child.getDefinition(); prop.releasePropertyDefinitionId(); for (NodeIterator iter = getNodesInternal(); iter.hasNext();) { AbstractJcrNode child = (AbstractJcrNode)iter.nextNode(); child.releaseNodeDefinitionId();
for (NodeIterator iter = getNodesInternal(); iter.hasNext();) { AbstractJcrNode child = (AbstractJcrNode)iter.nextNode(); NodeDefinition childDefinition = child.getDefinition(); prop.releasePropertyDefinitionId(); for (NodeIterator iter = getNodesInternal(); iter.hasNext();) { AbstractJcrNode child = (AbstractJcrNode)iter.nextNode(); child.releaseNodeDefinitionId();