/** updates an already existing object */ public void updateObject(int par1, Object par2Obj) { WatchableObject watchableobject = (WatchableObject) watchedObjects.get(Integer.valueOf(par1)); if (!par2Obj.equals(watchableobject.getObject())) { watchableobject.setObject(par2Obj); watchableobject.setWatching(true); objectChanged = true; } }
public void updateWatchedObjectsFromList(List par1List) { Iterator iterator = par1List.iterator(); do { if (!iterator.hasNext()) { break; } WatchableObject watchableobject = (WatchableObject) iterator.next(); WatchableObject watchableobject1 = (WatchableObject) watchedObjects.get(Integer.valueOf(watchableobject.getDataValueId())); if (watchableobject1 != null) { watchableobject1.setObject(watchableobject.getObject()); } } while (true); }