diff --git a/src/main/java/algorithmRunner/RunResult.java b/src/main/java/algorithmRunner/RunResult.java index c313ddf..b0c5e95 100644 --- a/src/main/java/algorithmRunner/RunResult.java +++ b/src/main/java/algorithmRunner/RunResult.java @@ -4,10 +4,10 @@ import graph.GraphStatistics; import graph.GraphType; -import java.time.LocalDate; +import java.time.LocalDateTime; public class RunResult { - private final LocalDate date; + private final LocalDateTime datetime; private final GraphStatistics patternGraphStatistics; private final GraphStatistics hostGraphStatistics; private Integer numberOfHighDegreeVertices = null; @@ -22,21 +22,20 @@ public RunResult(Graph hostGraph, String patternGraphFilepath) { patternGraphStatistics = new GraphStatistics(patternGraph, patternGraphFilepath, GraphType.PATTERN_GRAPH); hostGraphStatistics = new GraphStatistics(hostGraph, hostGraphFilepath, GraphType.HOST_GRAPH); - date = LocalDate.now(); + datetime = LocalDateTime.now(); } @Override public String toString() { - return "RunResult{" + - "date: " + date + - ", pattern graph statistics: " + patternGraphStatistics + - ", host graph statistics: " + hostGraphStatistics + - ", number of high degree vertices parameter: " + numberOfHighDegreeVertices + - ", maximum degree of remaining host graph: " + maximumDegreeOfRemainingVertices + - ", run status: " + status + - ", count: " + count + - ", runtime in milliseconds: " + runtimeInMilliseconds + - '}'; + return "RunResult\n" + + "datetime: " + datetime + "\n" + + "pattern graph statistics: " + patternGraphStatistics + "\n" + + "host graph statistics: " + hostGraphStatistics + "\n" + + "number of high degree vertices parameter: " + numberOfHighDegreeVertices + "\n" + + "maximum degree of remaining host graph: " + maximumDegreeOfRemainingVertices + "\n" + + "run status: " + status + "\n" + + "count: " + count + "\n" + + "runtime in milliseconds: " + runtimeInMilliseconds; } public void setMaximumDegreeOfRemainingVertices(int maximumDegreeOfRemainingVertices) { diff --git a/src/main/java/graph/GraphStatistics.java b/src/main/java/graph/GraphStatistics.java index c8c1415..2be5976 100644 --- a/src/main/java/graph/GraphStatistics.java +++ b/src/main/java/graph/GraphStatistics.java @@ -21,13 +21,11 @@ public GraphStatistics(Graph graph, String filepath, GraphType graphType) { @Override public String toString() { - return "GraphStatistics{" + - "filepath: " + filepath + '\'' + - ", graph type: " + graphType + - ", order: " + order + - ", number of edges: " + numEdges + - ", average degree: " + averageDegree + - ", maximum degree: " + maxDegree + - '}'; + return "filepath: " + filepath + "\n" + + "graph type: " + graphType + "\n" + + "order: " + order + "\n" + + "number of edges: " + numEdges + "\n" + + "average degree: " + averageDegree + "\n" + + "maximum degree: " + maxDegree + "\n" ; } } \ No newline at end of file