1 20 21 package org.jacorb.naming.namemanager; 22 23 class Updater 24 extends Thread  25 { 26 NSTree tree; 27 long mseconds; 28 29 public Updater(NSTree tr,int seconds) 30 { 31 tree=tr; 32 mseconds=seconds*1000; 33 } 34 35 public void run() 36 { 37 for (;;) 38 { 39 try 40 { 41 sleep(mseconds); 42 } 43 catch (Exception e) 44 {} 45 tree.update(); 46 } 47 } 48 public void setSeconds(int seconds) 49 { 50 mseconds=seconds*1000; 51 } 52 } 53 54 | Popular Tags |