title: Timer prevents the application from being closed
body: <p>I have a java function which is being called every x seconds in my program. i have wrapped my application with YAJSW. My question is: will the wrapper be able to stop the application even if the timer inside the programm is still running?! what is the way to stop the timer from outside the program? any idea other than reading from a file will be appreciated.</p>
  
  <pre><code> public static void main(String[] args) {           
  
          timer = new Timer();
          long Delay = 5000;
          TimerTask task = new TimerTask() {
              @Override
              public void run() {
                  DateFormat dateFormat = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss");
                  Date date = new Date();
                  String dateStr = dateFormat.format(date);
              }
          };
  
          timer.schedule(task, 0, Delay);
  } 
  </code></pre>