View Javadoc
1   package org.kuali.ole.utility;
2   
3   /**
4    * Created by pvsubrah on 4/7/15.
5    */
6   public class OleStopWatch {
7   
8       private long startTime = 0;
9       private long endTime   = 0;
10  
11      public void start(){
12          this.startTime = System.currentTimeMillis();
13      }
14  
15      public void end() {
16          this.endTime   = System.currentTimeMillis();
17      }
18  
19      public long getStartTime() {
20          return this.startTime;
21      }
22  
23      public long getEndTime() {
24          return this.endTime;
25      }
26  
27      public long getTotalTime() {
28          return this.endTime - this.startTime;
29      }
30  
31      public void reset() {
32          this.startTime = 0;
33          this.endTime = 0;
34      }
35  }