Class AccountValidator
java.lang.Object
com.google.gerrit.server.git.validators.AccountValidator
Validator that is used to ensure that new commits on any ref in
refs/users
are conforming
to the NoteDb format for accounts. Used when a user pushes to one of the refs in
refs/users
manually.-
Constructor Summary
ConstructorsConstructorDescriptionAccountValidator
(com.google.inject.Provider<IdentifiedUser> self, AllUsersName allUsersName, OutgoingEmailValidator emailValidator) -
Method Summary
Modifier and TypeMethodDescriptionvalidate
(Account.Id accountId, org.eclipse.jgit.lib.Repository allUsersRepo, org.eclipse.jgit.revwalk.RevWalk rw, org.eclipse.jgit.lib.ObjectId oldId, org.eclipse.jgit.lib.ObjectId newId) Returns a list of validation messages.
-
Constructor Details
-
AccountValidator
@Inject public AccountValidator(com.google.inject.Provider<IdentifiedUser> self, AllUsersName allUsersName, OutgoingEmailValidator emailValidator)
-
-
Method Details
-
validate
public List<String> validate(Account.Id accountId, org.eclipse.jgit.lib.Repository allUsersRepo, org.eclipse.jgit.revwalk.RevWalk rw, org.eclipse.jgit.lib.ObjectId oldId, org.eclipse.jgit.lib.ObjectId newId) throws IOException Returns a list of validation messages. An empty list means that there were no issues found. If the list is non-empty, the commit will be rejected.- Throws:
IOException
-