com.atlassian.confluence.user.crowd.jira.search
Enum QueryBuilder
java.lang.Object
java.lang.Enum<QueryBuilder>
com.atlassian.confluence.user.crowd.jira.search.QueryBuilder
- All Implemented Interfaces:
- Serializable, Comparable<QueryBuilder>
public enum QueryBuilder
- extends Enum<QueryBuilder>
Does the heavy work of converting a Crowd search query into an SQL query. There are separate query builders for
each query "target": users, groups, user->group membership and group->user membership.
USER
public static final QueryBuilder USER
GROUP
public static final QueryBuilder GROUP
USER_MEMBERSHIP
public static final QueryBuilder USER_MEMBERSHIP
GROUP_MEMBERSHIP
public static final QueryBuilder GROUP_MEMBERSHIP
values
public static QueryBuilder[] values()
- Returns an array containing the constants of this enum type, in
the order they are declared. This method may be used to iterate
over the constants as follows:
for (QueryBuilder c : QueryBuilder.values())
System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in
the order they are declared
valueOf
public static QueryBuilder valueOf(String name)
- Returns the enum constant of this type with the specified name.
The string must match exactly an identifier used to declare an
enum constant in this type. (Extraneous whitespace characters are
not permitted.)
- Parameters:
name
- the name of the enum constant to be returned.
- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant
with the specified name
NullPointerException
- if the argument is null
getNameOnlyRowMapper
public abstract org.springframework.jdbc.core.RowMapper getNameOnlyRowMapper()
getObjectRowMapper
public abstract org.springframework.jdbc.core.RowMapper getObjectRowMapper(long directoryId)
toWhereClause
public WhereClause toWhereClause(com.atlassian.crowd.embedded.api.SearchRestriction searchRestriction)
getObjectSqlQuery
protected abstract String getObjectSqlQuery(WhereClause where)
getNameOnlySqlQuery
protected abstract String getNameOnlySqlQuery(WhereClause where)
getPropertyName
protected abstract String getPropertyName(com.atlassian.crowd.search.query.entity.restriction.Property property)
isMatchEverything
protected abstract boolean isMatchEverything(com.atlassian.crowd.search.query.entity.restriction.TermRestriction restriction)