public static class CurveInterpolation.Builder extends Object implements CurveBuilder
| Constructor and Description |
|---|
Builder()
Build a curve.
|
Builder(CurveInterpolation curveInterpolation)
Build a curve by cloning a given curve.
|
Builder(String name,
LocalDate referenceDate)
Build a curve with a given name and given reference date.
|
| Modifier and Type | Method and Description |
|---|---|
CurveBuilder |
addPoint(double time,
double value,
boolean isParameter)
Add a point to the curve.
|
Curve |
build()
Build the curve.
|
CurveBuilder |
setExtrapolationMethod(CurveInterpolation.ExtrapolationMethod extrapolationMethod)
Set the extrapolation method of the curve.
|
CurveBuilder |
setInterpolationEntity(CurveInterpolation.InterpolationEntity interpolationEntity)
Set the interpolationEntity of the curve.
|
CurveBuilder |
setInterpolationMethod(CurveInterpolation.InterpolationMethod interpolationMethod)
Set the interpolation method of the curve.
|
public Builder()
public Builder(String name, LocalDate referenceDate)
name - The name of this curve.referenceDate - The reference date for this curve, i.e., the date which defined t=0.public Builder(CurveInterpolation curveInterpolation) throws CloneNotSupportedException
curveInterpolation - A curve to be used as starting point for the new curve.CloneNotSupportedException - Thrown, when the curve could not be cloned.public Curve build() throws CloneNotSupportedException
CurveBuilderbuild in interface CurveBuilderCloneNotSupportedException - Thrown if the curve could not be build (likely due to a template throwing CloneNotSupportedException.public CurveBuilder setInterpolationMethod(CurveInterpolation.InterpolationMethod interpolationMethod)
interpolationMethod - The interpolation method of the curve.public CurveBuilder setExtrapolationMethod(CurveInterpolation.ExtrapolationMethod extrapolationMethod)
extrapolationMethod - The extrapolation method of the curve.public CurveBuilder setInterpolationEntity(CurveInterpolation.InterpolationEntity interpolationEntity)
interpolationEntity - The interpolation entity of the curve.public CurveBuilder addPoint(double time, double value, boolean isParameter)
CurveBuilderaddPoint in interface CurveBuildertime - The time of the corresponding point.value - The value of the corresponding point.isParameter - A boolean, specifying weather the point should be considered a free parameter (true) or not (false). Fee parameters can be used to create a clone with modified values, see CurveInterpolation.getCloneForParameter(double[])Copyright © 2019. All rights reserved.