From 8aec43df690e9e59f7845d26adcd5a9e700d0c20 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Steffen=20M=C3=A4rcker?= Date: Thu, 1 Mar 2018 11:41:03 +0100 Subject: [PATCH] Return stop watch instance on start --- prism/src/common/StopWatch.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/prism/src/common/StopWatch.java b/prism/src/common/StopWatch.java index 4a3931a1..7393d55e 100644 --- a/prism/src/common/StopWatch.java +++ b/prism/src/common/StopWatch.java @@ -84,17 +84,18 @@ public class StopWatch } /** Start the stop watch (without task description) */ - public void start() + public StopWatch start() { - start(null); + return start(null); } /** Start the stop watch, store task description (may be {@code null}) */ - public void start(String taskDescription) + public StopWatch start(String taskDescription) { this.taskDescription = taskDescription; running = true; time = System.currentTimeMillis(); + return this; } /**