Package org.apache.jackrabbit.core.state

Examples of org.apache.jackrabbit.core.state.NodeState.addChildNodeEntry()


                // 2. re-parent target node
                targetState.setParentId(destParentNode.getNodeId());

                // 3. add child node entry to new parent
                destParentState.addChildNodeEntry(destName.getName(), targetId);
            }
        }

        // change definition of target
        targetNode.onRedefine(newTargetDef.unwrap());
View Full Code Here


        }

        // modify the state of 'this', i.e. the parent node
        NodeState thisState = (NodeState) getOrCreateTransientItemState();
        // add new child node entry
        thisState.addChildNodeEntry(name, nodeState.getNodeId());

        // add 'auto-create' properties defined in node type
        PropertyDefinition[] pda = nodeType.getAutoCreatedPropertyDefinitions();
        for (int i = 0; i < pda.length; i++) {
            PropertyDefinitionImpl pd = (PropertyDefinitionImpl) pda[i];
View Full Code Here

            state.removeAllChildNodeEntries();
            for (Iterator iter = cneList.iterator(); iter.hasNext();) {
                ChildNodeEntry cne = (ChildNodeEntry) iter.next();
                if (cne.getId().equals(id)) {
                    // replace entry with different name
                    state.addChildNodeEntry(nodeName, id);
                } else {
                    state.addChildNodeEntry(cne.getName(), cne.getId());
                }
            }
        }
View Full Code Here

                ChildNodeEntry cne = (ChildNodeEntry) iter.next();
                if (cne.getId().equals(id)) {
                    // replace entry with different name
                    state.addChildNodeEntry(nodeName, id);
                } else {
                    state.addChildNodeEntry(cne.getName(), cne.getId());
                }
            }
        }

        return node;
View Full Code Here

        // (6) modify the state of 'this', i.e. the parent node
        NodeId srcId = src.getNodeId();
        thisState = (NodeState) getOrCreateTransientItemState();
        // add new child node entry
        thisState.addChildNodeEntry(name, srcId);

        return itemMgr.getNode(srcId, parentId);
    }

    // -----------------------------------------------------------------< Item >
View Full Code Here

        // child nodes (list of name/uuid pairs)
        count = in.readInt();   // count
        for (int i = 0; i < count; i++) {
            Name name = readQName(in);
            NodeId parentId = readID(in);
            state.addChildNodeEntry(name, parentId);
        }

        if (version >= VERSION_1) {
            state.setModCount(readModCount(in));
        }
View Full Code Here

        // child nodes (list of name/uuid pairs)
        count = in.readInt();   // count
        for (int i = 0; i < count; i++) {
            Name name = readQName(in);
            NodeId parentId = readID(in);
            state.addChildNodeEntry(name, parentId);
        }

        if (version >= VERSION_1) {
            state.setModCount(readModCount(in));
        }
View Full Code Here

        state.setDefinitionId(nodeDefId);
        state.setModCount(modCount);
        Iterator iter = childNodeEntries.iterator();
        while (iter.hasNext()) {
            ChildNodeEntry e = (ChildNodeEntry) iter.next();
            state.addChildNodeEntry(e.getName(), e.getId());
        }
        state.setPropertyNames(properties.keySet());

        // add fake property entries
        state.addPropertyName(NameConstants.JCR_PRIMARYTYPE);
View Full Code Here

        // child nodes (list of name/uuid pairs)
        count = in.readInt();   // count
        for (int i = 0; i < count; i++) {
            Name name = readQName(in);
            NodeId parentId = readID(in);
            state.addChildNodeEntry(name, parentId);
        }

        if (version >= VERSION_1) {
            state.setModCount(readModCount(in));
        }
View Full Code Here

        state.setDefinitionId(nodeDefId);
        state.setModCount(modCount);
        Iterator iter = childNodeEntries.iterator();
        while (iter.hasNext()) {
            ChildNodeEntry e = (ChildNodeEntry) iter.next();
            state.addChildNodeEntry(e.getName(), e.getId());
        }
        state.setPropertyNames(properties.keySet());

        // add fake property entries
        state.addPropertyName(NameConstants.JCR_PRIMARYTYPE);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.