Changed interval and timeout to type int (seconds), added javadoc.