Example #1
0
 @Override
 public void detach() {
   super.detach();
   timer.cancel();
 }
Example #2
0
 @Override
 public void attach() {
   super.attach();
   timer.scheduleAtFixedRate(task, new Date(), 1000);
 }