org.quantlib.GridModelLocalVolSurface Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of quantlib Show documentation
Show all versions of quantlib Show documentation
Java language binding for QuantLib
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (https://www.swig.org).
* Version 4.2.1
*
* Do not make changes to this file unless you know what you are doing - modify
* the SWIG interface file instead.
* ----------------------------------------------------------------------------- */
package org.quantlib;
public class GridModelLocalVolSurface extends LocalVolTermStructure implements org.quantlib.helpers.QuantLibJNIHelpers.AutoCloseable {
private transient long swigCPtr;
private transient boolean swigCMemOwnDerived;
protected GridModelLocalVolSurface(long cPtr, boolean cMemoryOwn) {
super(QuantLibJNI.GridModelLocalVolSurface_SWIGSmartPtrUpcast(cPtr), true);
swigCMemOwnDerived = cMemoryOwn;
swigCPtr = cPtr;
}
protected static long getCPtr(GridModelLocalVolSurface obj) {
return (obj == null) ? 0 : obj.swigCPtr;
}
protected void swigSetCMemOwn(boolean own) {
swigCMemOwnDerived = own;
super.swigSetCMemOwn(own);
}
@SuppressWarnings({"deprecation", "removal"})
protected void finalize() {
delete();
}
public synchronized void delete() {
if (swigCPtr != 0) {
if (swigCMemOwnDerived) {
swigCMemOwnDerived = false;
QuantLibJNI.delete_GridModelLocalVolSurface(swigCPtr);
}
swigCPtr = 0;
}
super.delete();
}
public GridModelLocalVolSurface(Date referenceDate, DateVector dates, DoubleVectorVector strikes, DayCounter dayCounter, FixedLocalVolSurface.Extrapolation lowerExtrapolation, FixedLocalVolSurface.Extrapolation upperExtrapolation) {
this(QuantLibJNI.new_GridModelLocalVolSurface__SWIG_0(Date.getCPtr(referenceDate), referenceDate, DateVector.getCPtr(dates), dates, DoubleVectorVector.getCPtr(strikes), strikes, DayCounter.getCPtr(dayCounter), dayCounter, lowerExtrapolation.swigValue(), upperExtrapolation.swigValue()), true);
}
public GridModelLocalVolSurface(Date referenceDate, DateVector dates, DoubleVectorVector strikes, DayCounter dayCounter, FixedLocalVolSurface.Extrapolation lowerExtrapolation) {
this(QuantLibJNI.new_GridModelLocalVolSurface__SWIG_1(Date.getCPtr(referenceDate), referenceDate, DateVector.getCPtr(dates), dates, DoubleVectorVector.getCPtr(strikes), strikes, DayCounter.getCPtr(dayCounter), dayCounter, lowerExtrapolation.swigValue()), true);
}
public GridModelLocalVolSurface(Date referenceDate, DateVector dates, DoubleVectorVector strikes, DayCounter dayCounter) {
this(QuantLibJNI.new_GridModelLocalVolSurface__SWIG_2(Date.getCPtr(referenceDate), referenceDate, DateVector.getCPtr(dates), dates, DoubleVectorVector.getCPtr(strikes), strikes, DayCounter.getCPtr(dayCounter), dayCounter), true);
}
public Array params() {
return new Array(QuantLibJNI.GridModelLocalVolSurface_params(swigCPtr, this), true);
}
public void calibrate(CalibrationHelperVector arg0, OptimizationMethod arg1, EndCriteria arg2, Constraint constraint, DoubleVector weights, BoolVector fixParameters) {
QuantLibJNI.GridModelLocalVolSurface_calibrate__SWIG_0(swigCPtr, this, CalibrationHelperVector.getCPtr(arg0), arg0, OptimizationMethod.getCPtr(arg1), arg1, EndCriteria.getCPtr(arg2), arg2, Constraint.getCPtr(constraint), constraint, DoubleVector.getCPtr(weights), weights, BoolVector.getCPtr(fixParameters), fixParameters);
}
public void calibrate(CalibrationHelperVector arg0, OptimizationMethod arg1, EndCriteria arg2, Constraint constraint, DoubleVector weights) {
QuantLibJNI.GridModelLocalVolSurface_calibrate__SWIG_1(swigCPtr, this, CalibrationHelperVector.getCPtr(arg0), arg0, OptimizationMethod.getCPtr(arg1), arg1, EndCriteria.getCPtr(arg2), arg2, Constraint.getCPtr(constraint), constraint, DoubleVector.getCPtr(weights), weights);
}
public void calibrate(CalibrationHelperVector arg0, OptimizationMethod arg1, EndCriteria arg2, Constraint constraint) {
QuantLibJNI.GridModelLocalVolSurface_calibrate__SWIG_2(swigCPtr, this, CalibrationHelperVector.getCPtr(arg0), arg0, OptimizationMethod.getCPtr(arg1), arg1, EndCriteria.getCPtr(arg2), arg2, Constraint.getCPtr(constraint), constraint);
}
public void calibrate(CalibrationHelperVector arg0, OptimizationMethod arg1, EndCriteria arg2) {
QuantLibJNI.GridModelLocalVolSurface_calibrate__SWIG_3(swigCPtr, this, CalibrationHelperVector.getCPtr(arg0), arg0, OptimizationMethod.getCPtr(arg1), arg1, EndCriteria.getCPtr(arg2), arg2);
}
public EndCriteria.Type endCriteria() {
return EndCriteria.Type.swigToEnum(QuantLibJNI.GridModelLocalVolSurface_endCriteria(swigCPtr, this));
}
}