Class QueryGroups
- java.lang.Object
-
- com.google.gerrit.server.restapi.group.QueryGroups
-
- All Implemented Interfaces:
RestReadView<TopLevelResource>
,RestView<TopLevelResource>
public class QueryGroups extends Object implements RestReadView<TopLevelResource>
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
QueryGroups(GroupQueryBuilder queryBuilder, com.google.inject.Provider<GroupQueryProcessor> queryProcessorProvider, GroupJson json)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addOption(ListGroupsOption o)
List<GroupInfo>
apply(TopLevelResource resource)
Process the view operation by reading from the resource.void
setLimit(int limit)
void
setOptionFlagsHex(String hex)
void
setQuery(String query)
--query (-q) is already used byListGroups
void
setStart(int start)
-
-
-
Constructor Detail
-
QueryGroups
@Inject protected QueryGroups(GroupQueryBuilder queryBuilder, com.google.inject.Provider<GroupQueryProcessor> queryProcessorProvider, GroupJson json)
-
-
Method Detail
-
setQuery
public void setQuery(String query)
--query (-q) is already used byListGroups
-
setLimit
public void setLimit(int limit)
-
setStart
public void setStart(int start)
-
addOption
public void addOption(ListGroupsOption o)
-
setOptionFlagsHex
public void setOptionFlagsHex(String hex)
-
apply
public List<GroupInfo> apply(TopLevelResource resource) throws BadRequestException, MethodNotAllowedException, PermissionBackendException
Description copied from interface:RestReadView
Process the view operation by reading from the resource.- Specified by:
apply
in interfaceRestReadView<TopLevelResource>
- Parameters:
resource
- resource to read.- Returns:
- result to return to the client. Use
BinaryResult
to avoid automatic conversion to JSON. - Throws:
BadRequestException
- the request was incorrectly specified and cannot be handled by this view.MethodNotAllowedException
PermissionBackendException
-
-