Package com.ecyrd.speed4j

Examples of com.ecyrd.speed4j.StopWatch.stop()


        for( int i = 0; i < iterations; i++ )
        {
            Thread.sleep(10+ (long)(Math.random() * 10));
        }

        sw.stop("ok");

        assertEquals("ok", sw.getTag());

        assertTrue( sw.getTimeMicros() > iterations*10*1000L ); // No way this could be faster

View Full Code Here


        {
            StopWatch sw = swf.getStopWatch("foo");

            // Do nothing

            sw.stop("iteration:success");
        }

        total.stop("total");
        time = System.currentTimeMillis() - time;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.