@Test public void testGetElapsedMilliseconds() throws InterruptedException { Timer timer = Timer.getTimer(); assertEquals(0, timer.getElapsedMilliseconds()); timer.start(); timer.lap(); Thread.sleep(1); assertTrue(timer.getLapMilliseconds() > 0); }
public long getElapsedMilliseconds() { if (this.startTime != null) { return this.getFinalTime() - this.startTime; } return 0; }
Timer { public long getElapsedMilliseconds() { if (this.startTime != null) { return this.getFinalTime() - this.startTime; } return 0; } }
Timer { public long getElapsedMilliseconds() { if (this.startTime != null) { return this.getFinalTime() - this.startTime; } return 0; } private  Timer(); }
Timer { public long getElapsedMilliseconds() { if (this.startTime != null) { return this.getFinalTime() - this.startTime; } return 0; } private  Timer(); static Timer getTimer(); Timer start(); Timer stop(); Timer lap(); Timer reset(); long getElapsedMilliseconds(); long getLapMilliseconds(); }
Timer { public long getElapsedMilliseconds() { if (this.startTime != null) { return this.getFinalTime() - this.startTime; } return 0; } private  Timer(); static Timer getTimer(); Timer start(); Timer stop(); Timer lap(); Timer reset(); long getElapsedMilliseconds(); long getLapMilliseconds();  }