Class ResultItemSetCollector
java.lang.Object
org.onehippo.forge.content.exim.repository.jaxrs.util.ResultItemSetCollector
Utility to collect
ResultItems based on various conditions.-
Method Summary
Modifier and TypeMethodDescriptionstatic ResultcollectItemsFromExecutionParams(Session session, ExecutionParams params) CollectResultItems from the givenparamsby picking nodes from the given paths or querying nodes from the given queries.static voidfillResultItemsForNodePaths(Session session, Collection<String> nodePaths, boolean binary, Set<String> pathsCache, Result resultOut) static voidfillResultItemsFromQueries(Session session, Collection<String> queries, boolean binary, Set<String> pathsCache, Result resultOut)
-
Method Details
-
collectItemsFromExecutionParams
public static Result collectItemsFromExecutionParams(Session session, ExecutionParams params) throws RepositoryException CollectResultItems from the givenparamsby picking nodes from the given paths or querying nodes from the given queries.- Parameters:
session- JCR sessionparams- ExecutionParams instance- Returns:
- collected
ResultItems - Throws:
RepositoryException- if repository exception occurs
-
fillResultItemsForNodePaths
public static void fillResultItemsForNodePaths(Session session, Collection<String> nodePaths, boolean binary, Set<String> pathsCache, Result resultOut) throws RepositoryException - Parameters:
session- JCR sessionnodePaths- document or binary node paths to validatebinary- flag whether the node paths are for binary content or notpathsCache- node path cache set, which can be useful if you want to avoid putting the same items multiple times. This can be null.resultOut-Resultinstance- Throws:
RepositoryException- if repository exception occurs
-
fillResultItemsFromQueries
public static void fillResultItemsFromQueries(Session session, Collection<String> queries, boolean binary, Set<String> pathsCache, Result resultOut) throws RepositoryException - Parameters:
session- JCR sessionqueries- JCR query statements for documents or binariesbinary- flag whether the node paths are for binary content or notpathsCache- node path cache set, which can be useful if you want to avoid putting the same items multiple times. This can be null.resultOut-Resultinstance- Throws:
RepositoryException- if repository exception occurs
-