java.lang.Object
org.variantsync.studies.evolution.simulation.experiment.ResultAnalysis

public class ResultAnalysis extends Object
Performs the result analysis presented in our paper.
  • Constructor Details

    • ResultAnalysis

      public ResultAnalysis()
  • Method Details

    • processOutcome

      public static PatchOutcome processOutcome(String dataset, long runID, String sourceVariant, String targetVariant, org.variantsync.vevos.simulation.variability.SPLCommit commitV0, org.variantsync.vevos.simulation.variability.SPLCommit commitV1, FineDiff normalPatch, FineDiff filteredPatch, FineDiff resultDiffNormal, FineDiff resultDiffFiltered, OriginalDiff rejectsNormal, OriginalDiff rejectsFiltered, FineDiff sourceChanges, Set<String> skippedFilesNormal, Set<String> skippedFilesFiltered)
      Analyze the outcome of applying patches to a target variant
      Parameters:
      dataset - The considered SPL
      runID - The id of the analyzed run
      sourceVariant - The source variant's name
      targetVariant - The target variant's name
      commitV0 - The id of the parent commit
      commitV1 - The id of the child commit
      normalPatch - The FineDiff with all prepared changes
      filteredPatch - The FineDiff with all prepared changes after filtering
      resultDiffNormal - The difference between the patched target variant and the expected result
      resultDiffFiltered - The difference between the patched target variant and the expected result (with filtering)
      rejectsNormal - The rejected patches (aka. failed patches) without filtering
      rejectsFiltered - The rejected patches (aka. failed patches) with filtering
      sourceChanges - The difference between the two versions of the source variant
      skippedFilesNormal - List of files that were not found by patch and therefore not patched
      skippedFilesFiltered - List of files that were not found by patch and therefore not patched
      Returns:
      The patch outcome
    • main

      public static void main(String... args) throws IOException
      Run the result analysis on the collected results (i.e., results.txt). This method is called by the Docker container after the study has been run.
      Parameters:
      args - CL arguments
      Throws:
      IOException - If the results cannot be loaded
    • loadResultObjects

      public static org.variantsync.studies.evolution.simulation.experiment.ResultAnalysis.AccumulatedOutcome loadResultObjects(Path path) throws IOException
      Throws:
      IOException
    • parseResult

      public static PatchOutcome parseResult(List<String> lines)
    • percentage

      public static String percentage(long x, long y)