Package com.google.gerrit.server.fixes
Class FixReplacementInterpreter
- java.lang.Object
-
- com.google.gerrit.server.fixes.FixReplacementInterpreter
-
public class FixReplacementInterpreter extends Object
An interpreter forFixReplacements.
-
-
Constructor Summary
Constructors Constructor Description FixReplacementInterpreter(FileContentUtil fileContentUtil)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<TreeModification>toTreeModifications(org.eclipse.jgit.lib.Repository repository, ProjectState projectState, org.eclipse.jgit.lib.ObjectId patchSetCommitId, List<FixReplacement> fixReplacements)Transforms the givenFixReplacements intoTreeModifications.
-
-
-
Constructor Detail
-
FixReplacementInterpreter
@Inject public FixReplacementInterpreter(FileContentUtil fileContentUtil)
-
-
Method Detail
-
toTreeModifications
public List<TreeModification> toTreeModifications(org.eclipse.jgit.lib.Repository repository, ProjectState projectState, org.eclipse.jgit.lib.ObjectId patchSetCommitId, List<FixReplacement> fixReplacements) throws ResourceNotFoundException, IOException, ResourceConflictException
Transforms the givenFixReplacements intoTreeModifications.- Parameters:
repository- the affected Git repositoryprojectState- the affected projectpatchSetCommitId- the patch set which should be modifiedfixReplacements- the replacements which should be applied- Returns:
- a list of
TreeModifications representing the given replacements - Throws:
ResourceNotFoundException- if a file to which one of the replacements refers doesn't existResourceConflictException- if the replacements can't be transformed intoTreeModificationsIOException
-
-