Bug 225425 [DataBinding] Load of known null value in CompositeMap
Found by FindBugs: line 232 The variable referenced at this point is known to be null due to an earlier check against null. Although this is valid, it might be a mistake (perhaps you intended to refer to a different variable, or perhaps the earlier check to see if the variable is null should have been a check to see if it was nonnull). I don't know what the proper fix would be at this point. We also have a bug in Snippet017TableViewerWithDerivedColumns, or in CompositeMap: - start Snippet017 - select "Della Duck" - change Mother to: "Downy O'Drake" expected: Grandmother column for Della Duck changes to "unknown" actual: Grandmother column for Della Duck remains "Downy O'Drake"
bundles/org.eclipse.core.databinding.observable/src/org/eclipse/core/databinding/observable/map/CompositeMap.java
void addAndRemove(Set additions, Set removals) {
			wrappedSet.removeAll(removals);
			wrappedSet.addAll(additions);
			fireSetChange(Diffs.createSetDiff(additions, removals));
		}
	}
	private WritableSetPlus rangeSet = new WritableSetPlus();
	/**
	 * Creates a new composite map. Because the key set of the second map is
	 * determined by the value set of the given observable map
	 * <code>firstMap</code>, it cannot be passed in as an argument. Instead,
	 * the second map will be created by calling
	 * <code>secondMapFactory.createObservable(valueSet())</code>.
	 * 
	 * @param firstMap
	 *            the first map
	 * @param secondMapFactory
	 *            a factory that creates the second map when given an observable
	 *            set representing the value set of <code>firstMap</code>.
	 */
	public CompositeMap(IObservableMap firstMap,
			IObservableFactory secondMapFactory) {
		super(firstMap.getRealm(), new HashMap());
		this.firstMap = firstMap;
		firstMap.addMapChangeListener(firstMapListener);
		for (Iterator it = firstMap.entrySet().iterator(); it.hasNext();) {
			Map.Entry entry = (Entry) it.next();
			addMapping(entry.getKey(), entry.getValue());
			rangeSet.add(entry.getValue());