Bug 209484 [Databinding] ObservableSetContentProvider does not update knownElements
Build ID: M20071023-1652 Steps To Reproduce: 1. Use a ObservableSetContentProvider in a databinding table 2. Evaluate the knownElements member 3. knownElements is always empty More information: We use a modified ObservableSetContentProvider to bind a table to a model. Moreover, we would like to register for all known Elements in this table using the member 'knownElements' of this class. However, this elements in this member are always empty. There seems to be a bug in method setInput(): 1.) The set of known elements is created in the constructor. 2.) In the inputChanged method (and then in setInput()) the readable set is set to a new value, but the knownElements remains unchanged.
bundles/org.eclipse.core.databinding/src/org/eclipse/core/databinding/observable/set/WritableSet.java
/*******************************************************************************
 * Copyright (c) 2006, 2007 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *     Brad Reynolds - bug 147515
 *******************************************************************************/
package org.eclipse.core.databinding.observable.set;
import java.util.Collection;
import java.util.Collections;
import java.util.HashSet;
import java.util.Iterator;
import java.util.Set;
import org.eclipse.core.databinding.observable.Diffs;
import org.eclipse.core.databinding.observable.Realm;
/**
 * Mutable (writable) implementation of {@link IObservableSet}.
 * 
 * <p>
 * This class is thread safe. All state accessing methods must be invoked from
 * the {@link Realm#isCurrent() current realm}. Methods for adding and removing
 * listeners may be invoked from any thread.
 * </p>
 * 
 * @since 1.0
 */