Class QueryUtil
java.lang.Object
org.apache.jackrabbit.oak.security.user.query.QueryUtil
Common utilities used for user/group queries.
-
Method Summary
Modifier and TypeMethodDescriptionstatic @NotNull String
escapeForQuery
(@NotNull String value) static @NotNull String
escapeForQuery
(@NotNull String oakName, @NotNull NamePathMapper namePathMapper) static @NotNull String
escapeNodeName
(@NotNull String string) Escapestring
for matching in jcr escaped node namesstatic @NotNull String
static @NotNull org.apache.jackrabbit.oak.security.user.query.RelationOp
getCollation
(QueryBuilder.Direction direction) static @Nullable String
getID
(@Nullable Authorizable authorizable) static @NotNull String
getNodeTypeName
(@NotNull AuthorizableType type) Retrieve the node type name for the specified authorizable type.static @NotNull String
getSearchRoot
(AuthorizableType type, ConfigurationParameters config) Determine the search root for the given authorizable type based on the configured root path.
-
Method Details
-
getSearchRoot
@NotNull public static @NotNull String getSearchRoot(AuthorizableType type, ConfigurationParameters config) Determine the search root for the given authorizable type based on the configured root path.- Parameters:
type
- The authorizable type.config
- The configuration parameters.- Returns:
- The path of search root for the specified authorizable type.
-
getNodeTypeName
Retrieve the node type name for the specified authorizable type.- Parameters:
type
- The authorizable type.- Returns:
- The corresponding node type name.
-
escapeNodeName
Escapestring
for matching in jcr escaped node names- Parameters:
string
- string to escape- Returns:
- escaped string
-
format
@NotNull public static @NotNull String format(@NotNull @NotNull Value value) throws RepositoryException - Throws:
RepositoryException
-
escapeForQuery
@NotNull public static @NotNull String escapeForQuery(@NotNull @NotNull String oakName, @NotNull @NotNull NamePathMapper namePathMapper) -
escapeForQuery
-
getCollation
@NotNull public static @NotNull org.apache.jackrabbit.oak.security.user.query.RelationOp getCollation(@NotNull QueryBuilder.Direction direction) -
getID
-