Question: Raymond Hettinger has posted a [snippet](http://code.activestate.com/recipes/413137-call-a-functionmethod-x-times-per-second/#c3) where he uses the sched module available in the standard Python library in order to call functions with a specific rate (N times per second). I wonder if there is an equivalent library in Java.

Answer: 
Take a look at <http://quartz-scheduler.org/>

> 
> Quartz is a full-featured, open source job scheduling service that can be integrated with, or used along side virtually any Java EE or Java SE application - from the smallest stand-alone application to the largest e-commerce system.
> 
> 
>
How about using the [java.util.Timer class](http://docs.oracle.com/javase/1.4.2/docs/api/java/util/Timer.html)?

You can find the example code [here](http://www.roseindia.net/java/example/java/util/CertainAndRepeatTime.shtml)