Examples of denotesNode()


Examples of org.apache.jackrabbit.spi.ItemInfo.denotesNode()

     * @throws ItemNotFoundException  if no such node exists
     */
    public NodeInfo getNodeInfo(NodeId id) throws ItemNotFoundException {
        ItemInfo itemInfo = getItemInfo(id);

        return itemInfo.denotesNode()
            ? (NodeInfo) itemInfo
            : ItemInfoStore.<NodeInfo>notFound(id);
    }

    /**
 
View Full Code Here

Examples of org.apache.jackrabbit.spi.ItemInfo.denotesNode()

     * @throws ItemNotFoundException  if no such property exists
     */
    public PropertyInfo getPropertyInfo(PropertyId id) throws ItemNotFoundException {
        ItemInfo itemInfo = getItemInfo(id);

        return itemInfo.denotesNode()
            ? ItemInfoStore.<PropertyInfo>notFound(id)
            : (PropertyInfo) itemInfo;
    }

    /**
 
View Full Code Here

Examples of org.apache.jackrabbit.spi.ItemInfo.denotesNode()

                info = cached.info;
            } else {
                // otherwise retrieve item info from service and cache the whole batch
                Iterator<? extends ItemInfo> infos = service.getItemInfos(sessionInfo, nodeId);
                info = first(infos, cache, entry.getGeneration());
                if (info == null || !info.denotesNode()) {
                    throw new ItemNotFoundException("NodeId: " + nodeId);
                }
            }

            assertMatchingPath(info, entry);
View Full Code Here

Examples of org.apache.jackrabbit.spi.ItemInfo.denotesNode()

            ItemInfo info;
            if (cached == null) {
                // or from service if not in cache
                infos = service.getItemInfos(sessionInfo, nodeId);
                info = first(infos, null, 0);
                if (info == null || !info.denotesNode()) {
                    throw new ItemNotFoundException("NodeId: " + nodeId);
                }
            } else {
                info = cached.info;
            }
View Full Code Here

Examples of org.apache.jackrabbit.spi.ItemInfo.denotesNode()

                info = cached.info;
            } else {
                // otherwise retrieve item info from service and cache the whole batch
                Iterator<? extends ItemInfo> infos = service.getItemInfos(sessionInfo, propertyId);
                info = first(infos, cache, entry.getGeneration());
                if (info == null || info.denotesNode()) {
                    throw new ItemNotFoundException("PropertyId: " + propertyId);
                }
            }

            assertMatchingPath(info, entry);
View Full Code Here

Examples of org.apache.jackrabbit.spi.ItemInfo.denotesNode()

            ItemInfo info;
            if (cached == null) {
                // or from service if not in cache
                infos = service.getItemInfos(sessionInfo, propertyId);
                info = first(infos, null, 0);
                if (info == null || info.denotesNode()) {
                    throw new ItemNotFoundException("PropertyId: " + propertyId);
                }
            } else {
                info = cached.info;
            }
View Full Code Here

Examples of org.apache.jackrabbit.spi.ItemInfo.denotesNode()

        NodeId id = rs.getIdFactory().createNodeId(nid, resolver.getQPath("aNode"));
        Iterator<? extends ItemInfo> it = rs.getItemInfos(si, id);
        while (it.hasNext()) {
            ItemInfo info = it.next();
            if (info.denotesNode()) {
                NodeInfo nInfo = (NodeInfo) info;
                assertEquals(NameConstants.NT_UNSTRUCTURED, nInfo.getNodetype());
                Iterator<ChildInfo> childIt = nInfo.getChildInfos();
                assertTrue(childIt == null || !childIt.hasNext());
                assertEquals(id, nInfo.getId());
View Full Code Here

Examples of org.apache.jackrabbit.spi.ItemInfo.denotesNode()

        assertFalse(pi.getType() == PropertyType.UNDEFINED);

        Iterator<? extends ItemInfo> it = rs.getItemInfos(si, nid);
        while (it.hasNext()) {
            ItemInfo info = it.next();
            if (!info.denotesNode()) {
                PropertyInfo pInfo = (PropertyInfo) info;
                if (propName.equals((pInfo.getId().getName()))) {
                    assertTrue(pi.isMultiValued());
                    assertEquals(Arrays.asList(new QValue[0]), Arrays.asList(pi.getValues()));
                    assertFalse(pi.getType() == PropertyType.UNDEFINED);
View Full Code Here

Examples of org.apache.jackrabbit.spi.ItemInfo.denotesNode()

    private PropertyInfo getPropertyInfo(NodeId parentId, Name propName) throws RepositoryException {
        Iterator<? extends ItemInfo> it = rs.getItemInfos(si, parentId);
        while (it.hasNext()) {
            ItemInfo info = it.next();
            if (!info.denotesNode()) {
                PropertyInfo pInfo = (PropertyInfo) info;
                if (propName.equals((pInfo.getId().getName()))) {
                    return pInfo;
                }
            }
View Full Code Here

Examples of org.apache.jackrabbit.spi.ItemInfo.denotesNode()

        // This reduces the part of the hierarchy to traverse. For large batches this
        // optimization results in about 25% speed up.
        NodeEntry approxParentEntry = nodeState.getNodeEntry();
        while (infos.hasNext()) {
            ItemInfo info = infos.next();
            if (info.denotesNode()) {
                approxParentEntry = createDeepNodeState((NodeInfo) info, approxParentEntry, infos).getNodeEntry();
            } else {
                createDeepPropertyState((PropertyInfo) info, approxParentEntry, infos);
            }
        }
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.