Search in sources :

Example 1 with RangeMapping

use of com.google.gerrit.server.patch.GitPositionTransformer.RangeMapping in project gerrit by GerritCodeReview.

the class DiffMappings method toMapping.

public static Mapping toMapping(PatchListEntry patchListEntry) {
    FileMapping fileMapping = toFileMapping(patchListEntry);
    ImmutableSet<RangeMapping> rangeMappings = toRangeMappings(patchListEntry);
    return Mapping.create(fileMapping, rangeMappings);
}
Also used : FileMapping(com.google.gerrit.server.patch.GitPositionTransformer.FileMapping) RangeMapping(com.google.gerrit.server.patch.GitPositionTransformer.RangeMapping)

Example 2 with RangeMapping

use of com.google.gerrit.server.patch.GitPositionTransformer.RangeMapping in project gerrit by GerritCodeReview.

the class DiffMappings method toMapping.

public static Mapping toMapping(FileEdits fileEdits) {
    FileMapping fileMapping = FileMapping.forFile(fileEdits.oldPath(), fileEdits.newPath());
    ImmutableSet<RangeMapping> rangeMappings = toRangeMappings(fileEdits.edits());
    return Mapping.create(fileMapping, rangeMappings);
}
Also used : FileMapping(com.google.gerrit.server.patch.GitPositionTransformer.FileMapping) RangeMapping(com.google.gerrit.server.patch.GitPositionTransformer.RangeMapping)

Aggregations

FileMapping (com.google.gerrit.server.patch.GitPositionTransformer.FileMapping)2 RangeMapping (com.google.gerrit.server.patch.GitPositionTransformer.RangeMapping)2