Bug 159940 [DataBinding] DataBindingContext shouldn't expose the bindings list as a mutable list
Currently in DataBindingContext getBindings() exposes the bindings observable list as a mutable observable list. I think we need to make this an unmodifiable list and also add a removeBinding(Binding binding) method to the API of DataBindingContext so that the DBC can remove itself from the binding when removed from the DBC. I'll create a patch soon.
tests/org.eclipse.jface.tests.databinding/src/org/eclipse/jface/tests/databinding/DatabindingContextTest.java
return null;
			}
		});
		assertEquals(o2, settableValue1.getValue());
		assertEquals(
				"Both binding events should be called the same number of times",
				calls[0], calls[1]);
		settableValue1.setValue(o1);
		assertEquals(o1, settableValue2.getValue());
		assertEquals(
				"Both binding events should be called the same number of times",
				calls[0], calls[1]);
		settableValue2.setValue(o2);
		assertEquals(
				"Both binding events should be called the same number of times",
				calls[0], calls[1]);
		assertEquals(o2, settableValue1.getValue());
		
		binding.addBindingEventListener(new BindingAdapter() {
			public ValidationError bindingEvent(BindingEvent e) {
				if (e.pipelinePosition == org.eclipse.jface.databinding.BindingEvent.PIPELINE_AFTER_CONVERT) {
					return ValidationError.error("error");
				}
				return null;
			}
		});
		settableValue1.setValue(o1);
		settableValue2.setValue(o2);
		assertEquals(
				"Both binding events should be called the same number of times",