summaryrefslogtreecommitdiff
path: root/NET/worlds/network/Timer.java
blob: 4e280d5e239c56ccbf34a0e87a73fd4d645f92ec (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
/*    */ package NET.worlds.network;
/*    */ 
/*    */ import NET.worlds.core.Std;
/*    */ import java.io.PrintStream;
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ public class Timer
/*    */ {
/*    */   int _startTime;
/*    */   String _msg;
/*    */   
/*    */   public Timer(String msg)
/*    */   {
/* 21 */     this._msg = msg;
/* 22 */     this._startTime = Std.getRealTime();
/*    */   }
/*    */   
/*    */   public void stop(int minDur) {
/* 26 */     int endTime = Std.getRealTime();
/* 27 */     int duration = endTime - this._startTime;
/* 28 */     if (duration > minDur) {
/* 29 */       System.out.println(this._msg + ": " + duration + "ms");
/*    */     }
/*    */   }
/*    */ }


/* Location:              C:\Program Files (x86)\Worlds Inc\WorldsPlayer - Win7\lib\worlds.jar!\NET\worlds\network\Timer.class
 * Java compiler version: 6 (50.0)
 * JD-Core Version:       0.7.1
 */