Bug 127861 [DataBinding] Mark API provisional
examples/org.eclipse.jface.examples.databinding/src/org/eclipse/jface/examples/databinding/contentprovider/test/SomeMathFunction.java
private IReadableSet domain;
	private int op = OP_ROUND;
	
	public SomeMathFunction(IReadableSet domain) {
		this.domain = domain;
	}
	
	public void setOperation(int operation) {
		this.op = operation;
		
		
		
		
		
		fireChangeEvent(new ChangeEvent(this, ChangeEvent.CHANGE_MANY, null, domain.toCollection()));
	}
	
	protected Object doComputeResult(Object input) {
		switch (op) {
		case OP_IDENTITY: 
			return input;
		case OP_MULTIPLY:
			return new Double((((Double)input).doubleValue() * 2.0));
		case OP_ROUND:
			return new Double(Math.floor((((Double)input).doubleValue())));
		}
		return input;
	}
}