Return to Snippet

Revision: 16535
at August 7, 2009 08:36 by berndschiffer


Updated Code
def timeLogged (Closure c) {
    long start = - System.currentTimeMillis()
    c.call()
    println "duration in sec: " + (System.currentTimeMillis() + start) / 1000;
}

Revision: 16534
at August 7, 2009 08:19 by berndschiffer


Initial Code
def timeLogged (Closure c) {
    long start = - System.currentTimeMillis()
    c.call()
    println "duration in sec: " + (System.currentTimeMillis() + start) / 1000;
}

Initial URL
http://berndschiffer.blogspot.com/2009/08/beispiel-fur-refactoring-von-beispiel.html

Initial Description


Initial Title
Stefans Implementierung der Closure

Initial Tags
textmate, groovy

Initial Language
Groovy