Examples of includeNode()


Examples of org.modeshape.jcr.cache.document.NodeCacheIterator.NodeFilter.includeNode()

        if (nodeFilter != null) {

            // Find the node by path ...
            NodeCache cache = repo.getWorkspaceCache(workspaceName);
            CachedNode node = getNodeAtPath(path, cache);
            if (node != null && nodeFilter.includeNode(node, cache)) {
                return NodeSequence.withNodes(Collections.singleton(node), score, workspaceName);
            }
        }
        return NodeSequence.emptySequence(1);
    }
View Full Code Here

Examples of org.modeshape.jcr.cache.document.NodeCacheIterator.NodeFilter.includeNode()

            // Find the node by path ...
            NodeCache cache = repo.getWorkspaceCache(workspaceName);
            if (NodeKey.isValidFormat(identifier)) {
                NodeKey key = new NodeKey(identifier);
                CachedNode node = cache.getNode(key);
                if (node != null && nodeFilter.includeNode(node, cache)) {
                    return NodeSequence.withNodes(Collections.singleton(node), score, workspaceName);
                }
            }
            // Try with the same source and workspace key as the root node ...
            NodeKey key = cache.getRootKey().withId(identifier);
View Full Code Here

Examples of org.modeshape.jcr.cache.document.NodeCacheIterator.NodeFilter.includeNode()

                }
            }
            // Try with the same source and workspace key as the root node ...
            NodeKey key = cache.getRootKey().withId(identifier);
            CachedNode node = cache.getNode(key);
            if (node != null && nodeFilter.includeNode(node, cache)) {
                return NodeSequence.withNodes(Collections.singleton(node), score, workspaceName);
            }
        }
        return NodeSequence.emptySequence(1);
    }
View Full Code Here

Examples of org.modeshape.jcr.cache.document.NodeCacheIterator.NodeFilter.includeNode()

                // Only add those children that are queryable ...
                ChildReferences childRefs = parentNode.getChildReferences(cache);
                List<CachedNode> results = new ArrayList<CachedNode>((int)childRefs.size());
                for (ChildReference childRef : childRefs) {
                    CachedNode child = cache.getNode(childRef);
                    if (compositeFilter.includeNode(child, cache)) {
                        results.add(child);
                    }
                }
                return NodeSequence.withNodes(results, score, workspaceName);
            }
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.