Package com.google.gerrit.server.change
Class ReviewerModifier
java.lang.Object
com.google.gerrit.server.change.ReviewerModifier
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enum
Controls which failures should be ignored.static class
class
static class
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
static final int
-
Method Summary
Modifier and TypeMethodDescriptionccCurrentUser
(CurrentUser user, RevisionResource revision) static boolean
isLegalReviewerGroup
(AccountGroup.UUID groupUUID) newReviewerInput
(String reviewer, ReviewerState state, NotifyHandling notify) newReviewerInputFromCommitIdentity
(Change change, org.eclipse.jgit.lib.ObjectId commitId, Account.Id accountId, NotifyHandling notify, Account.Id mostRecentUploader) prepare
(ChangeNotes notes, CurrentUser user, ReviewerInput input, boolean allowGroup) Prepare application of a singleReviewerInput
.prepare
(ChangeNotes notes, CurrentUser user, Iterable<? extends ReviewerInput> inputs, boolean allowGroup)
-
Field Details
-
DEFAULT_MAX_REVIEWERS_WITHOUT_CHECK
public static final int DEFAULT_MAX_REVIEWERS_WITHOUT_CHECK- See Also:
-
DEFAULT_MAX_REVIEWERS
public static final int DEFAULT_MAX_REVIEWERS- See Also:
-
-
Method Details
-
newReviewerInput
public static ReviewerModifier.InternalReviewerInput newReviewerInput(String reviewer, ReviewerState state, NotifyHandling notify) -
newReviewerInputFromCommitIdentity
public static Optional<ReviewerModifier.InternalReviewerInput> newReviewerInputFromCommitIdentity(Change change, org.eclipse.jgit.lib.ObjectId commitId, Account.Id accountId, NotifyHandling notify, Account.Id mostRecentUploader) -
prepare
public ReviewerModifier.ReviewerModification prepare(ChangeNotes notes, CurrentUser user, ReviewerInput input, boolean allowGroup) throws IOException, PermissionBackendException, org.eclipse.jgit.errors.ConfigInvalidException Prepare application of a singleReviewerInput
.- Parameters:
notes
- change notes.user
- user performing the reviewer addition.input
- input describing user or group to add as a reviewer.allowGroup
- whether to allow- Returns:
- handle describing the addition operation. If the
op
field is present, this operation may be added to aBatchUpdate
. Otherwise, theerror
field contains information about an error that occurred - Throws:
IOException
PermissionBackendException
org.eclipse.jgit.errors.ConfigInvalidException
-
ccCurrentUser
public ReviewerModifier.ReviewerModification ccCurrentUser(CurrentUser user, RevisionResource revision) -
isLegalReviewerGroup
-
prepare
public ReviewerModifier.ReviewerModificationList prepare(ChangeNotes notes, CurrentUser user, Iterable<? extends ReviewerInput> inputs, boolean allowGroup) throws IOException, PermissionBackendException, org.eclipse.jgit.errors.ConfigInvalidException - Throws:
IOException
PermissionBackendException
org.eclipse.jgit.errors.ConfigInvalidException
-