Class FindMedianCommitTime
java.lang.Object
org.variantsync.diffdetective.experiments.esecfse22.FindMedianCommitTime
Program to find the median commit time after the
EditClassValidation
has been performed.
This program will iterate through all commit times reported by the validation, load them,
and find average time, median time, the fastest, and the slowest commit.- Author:
- Paul Bittner
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic AutomationResult
getResultOfDirectory
(Path directory) Summarizes the commit time results found in the given validation output directory.static void
Main method.private static Stream<CommitProcessTime>
Parses all CommitProcessTimes in the given file.
-
Field Details
-
outputFile
File to write the result to.
-
-
Constructor Details
-
FindMedianCommitTime
public FindMedianCommitTime()
-
-
Method Details
-
main
Main method. Expects exactly one argument: The path to the root directory of the validation output.- Parameters:
args
- An array of size 1, containing the path to validation output is expected.- Throws:
IOException
- whengetResultOfDirectory(java.nio.file.Path)
throws.
-
getResultOfDirectory
Summarizes the commit time results found in the given validation output directory. The directory should point to the root of the directory in which the results of an execution of theEditClassValidation
can be found.- Parameters:
directory
- Validation output directory.- Returns:
- Summary of commit process times with various speed statistics.
- Throws:
IOException
- when iterating the files in the given directory fails for some reason.
-
parse
Parses all CommitProcessTimes in the given file.- Parameters:
file
- Path to a commit times file (ending with.committimes.txt
).- Returns:
- A stream of the CommitProcessTimes in the given file.
-