Bug 174555 [DataBinding] Run validation on binding construction
When a binding is created the assumption is that the UI is synchronized with the model. This means that the UI should reflect the state of the model's validity as well. In order to ensure that the UI reflects the model's validity the consumer needs to force a copy to model on instantiation of every binding. We need to remove this requirement.
bundles/org.eclipse.core.databinding/src/org/eclipse/core/internal/databinding/ValueBinding.java
import org.eclipse.core.databinding.validation.IValidator;
import org.eclipse.core.databinding.validation.ValidationStatus;
import org.eclipse.core.runtime.Assert;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
/**
 * @since 1.0
 * 
 */
public class ValueBinding extends Binding {
	private final IObservableValue target;
	private final IObservableValue model;
	private IConverter targetToModelConverter;
	private IConverter modelToTargetConverter;
	private boolean updatingTarget = false;
	private boolean updatingModel = false;
	private WritableValue partialValidationErrorObservable;
	private WritableValue validationErrorObservable;
	private IValueChangeListener targetChangeListener;
	private Map targetValidators = new HashMap();
	private Map modelValidators = new HashMap();
	private static final Integer[] VALIDATION_POSITIONS = new Integer[] {
			new Integer(BindingEvent.PIPELINE_VALUE_CHANGING),
			new Integer(BindingEvent.PIPELINE_AFTER_GET),
			new Integer(BindingEvent.PIPELINE_AFTER_CONVERT),
			new Integer(BindingEvent.PIPELINE_BEFORE_CHANGE) };
	/**
	 * @param target
	 * @param model
	 * @param bindSpec