sascha@3034: package de.intevation.flys.jfree; sascha@3034: sascha@3034: import de.intevation.flys.artifacts.math.Function; sascha@3034: sascha@3034: import org.jfree.data.function.Function2D; sascha@3034: sascha@3034: public class Function2DAdapter sascha@3034: implements Function2D sascha@3034: { sascha@3034: protected Function function; sascha@3034: sascha@3034: public Function2DAdapter() { sascha@3034: } sascha@3034: sascha@3034: public Function2DAdapter(Function function) { sascha@3034: this.function = function; sascha@3034: } sascha@3034: sascha@3034: public Function getFunction() { sascha@3034: return function; sascha@3034: } sascha@3034: sascha@3034: public void setFunction(Function function) { sascha@3034: this.function = function; sascha@3034: } sascha@3034: sascha@3034: @Override sascha@3034: public double getValue(double x) { sascha@3034: return function.value(x); sascha@3034: } sascha@3034: } sascha@3034: // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :