Skip to content

Commit

Permalink
Return this from startTimer()
Browse files Browse the repository at this point in the history
  • Loading branch information
afs committed May 20, 2023
1 parent 971799a commit b3a0541
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion jena-base/src/main/java/org/apache/jena/atlas/lib/Timer.java
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,13 @@ public class Timer {

public Timer() {}

public void startTimer() {
public Timer startTimer() {
if ( inTimer )
throw new AtlasException("Already in timer");
timeStart = System.currentTimeMillis();
timeFinish = -1;
inTimer = true;
return this;
}

/** Stop timing and return the elapsed time in milliseconds */
Expand Down

0 comments on commit b3a0541

Please sign in to comment.