Class GroupsDelegator
java.lang.Object
com.perforce.p4java.impl.mapbased.server.cmd.BaseDelegator
com.perforce.p4java.impl.mapbased.server.cmd.GroupsDelegator
- All Implemented Interfaces:
IGroupsDelegator
- Since:
- 12/09/2016
-
Field Summary
Fields inherited from class com.perforce.p4java.impl.mapbased.server.cmd.BaseDelegator
MAX_LIMIT_SUPPORTED_MIN_VERSION, QUERY_EXPRESSIONS_SUPPORTED_MIN_VERSION, USER_RESTRICTIONS_SUPPORTED_MIN_VERSION -
Constructor Summary
ConstructorsConstructorDescriptionGroupsDelegator(IOptionsServer server) Instantiate a new GroupsDelegator for the given server implemention. -
Method Summary
Modifier and TypeMethodDescriptiongetUserGroups(String userOrGroupName, boolean indirect, boolean displayValues, int maxGroups) Implemented on behalf of legacy clients.getUserGroups(String userOrGroupName, GetUserGroupsOptions opts) Get a list of Perforce user groups from the server.
-
Constructor Details
-
GroupsDelegator
Instantiate a new GroupsDelegator for the given server implemention.- Parameters:
server- the server to delegate for
-
-
Method Details
-
getUserGroups
public List<IUserGroup> getUserGroups(String userOrGroupName, GetUserGroupsOptions opts) throws P4JavaException Description copied from interface:IGroupsDelegatorGet a list of Perforce user groups from the server.Note that the Perforce server considers it an error to have both indirect and displayValues parameters set true; this will cause the server to throw a RequestException with an appropriate usage message.
- Specified by:
getUserGroupsin interfaceIGroupsDelegator- Parameters:
userOrGroupName- if non-null, restrict the list to the specified group or username.opts- GetUserGroupsOptions object describing optional parameters; if null, no options are set- Returns:
- a non-null but possibly-empty list of qualifying groups.
- Throws:
P4JavaException- if any error occurs in the processing of this method.
-
getUserGroups
public List<IUserGroup> getUserGroups(String userOrGroupName, boolean indirect, boolean displayValues, int maxGroups) throws ConnectionException, RequestException, AccessException Implemented on behalf of legacy clients.- Parameters:
userOrGroupName- userOrGroupNameindirect- indirectdisplayValues- displayValuesmaxGroups- maxGroups- Returns:
- list of groups
- Throws:
ConnectionException- on errorRequestException- on errorAccessException- on error- See Also:
-