Package com.google.gerrit.server.project
Class SubmitRequirementConfigValidator
- java.lang.Object
-
- com.google.gerrit.server.project.SubmitRequirementConfigValidator
-
- All Implemented Interfaces:
CommitValidationListener
public class SubmitRequirementConfigValidator extends Object implements CommitValidationListener
Validates the expressions of submit requirements inproject.config
.Other validation of submit requirements is done in
ProjectConfig
, seeProjectConfig#loadSubmitRequirementSections(Config)
.The validation of the expressions cannot be in
ProjectConfig
as it requires injectingSubmitRequirementsEvaluator
and we cannot do injections intoProjectConfig
(sinceProjectConfig
is cached in the project cache).
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<CommitValidationMessage>
onCommitReceived(CommitReceivedEvent event)
Commit validation.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.google.gerrit.server.git.validators.CommitValidationListener
shouldValidateAllCommits
-
-
-
-
Method Detail
-
onCommitReceived
public List<CommitValidationMessage> onCommitReceived(CommitReceivedEvent event) throws CommitValidationException
Description copied from interface:CommitValidationListener
Commit validation.- Specified by:
onCommitReceived
in interfaceCommitValidationListener
- Parameters:
event
- commit event details- Returns:
- list of validation messages
- Throws:
CommitValidationException
- if validation fails
-
-