class Test { public static void main(String[] args) { StopWatch stopwatch1 = new StopWatch(); // object of stopwatch class stopwatch1.start(10); // reseting the start time through method calling stopwatch1.stop(20); // setting the stop time through method calling stopwatch1.getStartTime(); // getting the start time through method calling stopwatch1.getEndTime(); // getting the stop time through method calling stopwatch1.getElapsedTime(); // getting the elapsed time through method calling } }