@@ -486,17 +486,38 @@ namespace RQuantLib {
486486 return Rcpp::as<bool >(rcpp_result_gen);
487487 }
488488
489- inline double europeanOptionImpliedVolatilityEngine (std::string type, double value, double underlying, double strike, double dividendYield, double riskFreeRate, double maturity, double volatility) {
490- typedef SEXP (*Ptr_europeanOptionImpliedVolatilityEngine)(SEXP,SEXP,SEXP,SEXP,SEXP,SEXP,SEXP,SEXP);
489+ inline double europeanOptionImpliedVolatilityEngine (std::string type, double value, double underlying, double strike, double dividendYield, double riskFreeRate, double maturity, double volatility, int dayCounter ) {
490+ typedef SEXP (*Ptr_europeanOptionImpliedVolatilityEngine)(SEXP,SEXP,SEXP,SEXP,SEXP,SEXP,SEXP,SEXP,SEXP );
491491 static Ptr_europeanOptionImpliedVolatilityEngine p_europeanOptionImpliedVolatilityEngine = NULL ;
492492 if (p_europeanOptionImpliedVolatilityEngine == NULL ) {
493- validateSignature (" double(*europeanOptionImpliedVolatilityEngine)(std::string,double,double,double,double,double,double,double)" );
493+ validateSignature (" double(*europeanOptionImpliedVolatilityEngine)(std::string,double,double,double,double,double,double,double,int )" );
494494 p_europeanOptionImpliedVolatilityEngine = (Ptr_europeanOptionImpliedVolatilityEngine)R_GetCCallable (" RQuantLib" , " _RQuantLib_europeanOptionImpliedVolatilityEngine" );
495495 }
496496 RObject rcpp_result_gen;
497497 {
498498 RNGScope RCPP_rngScope_gen;
499- rcpp_result_gen = p_europeanOptionImpliedVolatilityEngine (Shield<SEXP>(Rcpp::wrap (type)), Shield<SEXP>(Rcpp::wrap (value)), Shield<SEXP>(Rcpp::wrap (underlying)), Shield<SEXP>(Rcpp::wrap (strike)), Shield<SEXP>(Rcpp::wrap (dividendYield)), Shield<SEXP>(Rcpp::wrap (riskFreeRate)), Shield<SEXP>(Rcpp::wrap (maturity)), Shield<SEXP>(Rcpp::wrap (volatility)));
499+ rcpp_result_gen = p_europeanOptionImpliedVolatilityEngine (Shield<SEXP>(Rcpp::wrap (type)), Shield<SEXP>(Rcpp::wrap (value)), Shield<SEXP>(Rcpp::wrap (underlying)), Shield<SEXP>(Rcpp::wrap (strike)), Shield<SEXP>(Rcpp::wrap (dividendYield)), Shield<SEXP>(Rcpp::wrap (riskFreeRate)), Shield<SEXP>(Rcpp::wrap (maturity)), Shield<SEXP>(Rcpp::wrap (volatility)), Shield<SEXP>(Rcpp::wrap (dayCounter)));
500+ }
501+ if (rcpp_result_gen.inherits (" interrupted-error" ))
502+ throw Rcpp::internal::InterruptedException ();
503+ if (Rcpp::internal::isLongjumpSentinel (rcpp_result_gen))
504+ throw Rcpp::LongjumpException (rcpp_result_gen);
505+ if (rcpp_result_gen.inherits (" try-error" ))
506+ throw Rcpp::exception (Rcpp::as<std::string>(rcpp_result_gen).c_str ());
507+ return Rcpp::as<double >(rcpp_result_gen);
508+ }
509+
510+ inline double europeanOptionImpliedVolatilityEngineByDate (std::string type, double value, double underlying, double strike, double dividendYield, double riskFreeRate, QuantLib::Date exDate, double volatility, int dayCounter) {
511+ typedef SEXP (*Ptr_europeanOptionImpliedVolatilityEngineByDate)(SEXP,SEXP,SEXP,SEXP,SEXP,SEXP,SEXP,SEXP,SEXP);
512+ static Ptr_europeanOptionImpliedVolatilityEngineByDate p_europeanOptionImpliedVolatilityEngineByDate = NULL ;
513+ if (p_europeanOptionImpliedVolatilityEngineByDate == NULL ) {
514+ validateSignature (" double(*europeanOptionImpliedVolatilityEngineByDate)(std::string,double,double,double,double,double,QuantLib::Date,double,int)" );
515+ p_europeanOptionImpliedVolatilityEngineByDate = (Ptr_europeanOptionImpliedVolatilityEngineByDate)R_GetCCallable (" RQuantLib" , " _RQuantLib_europeanOptionImpliedVolatilityEngineByDate" );
516+ }
517+ RObject rcpp_result_gen;
518+ {
519+ RNGScope RCPP_rngScope_gen;
520+ rcpp_result_gen = p_europeanOptionImpliedVolatilityEngineByDate (Shield<SEXP>(Rcpp::wrap (type)), Shield<SEXP>(Rcpp::wrap (value)), Shield<SEXP>(Rcpp::wrap (underlying)), Shield<SEXP>(Rcpp::wrap (strike)), Shield<SEXP>(Rcpp::wrap (dividendYield)), Shield<SEXP>(Rcpp::wrap (riskFreeRate)), Shield<SEXP>(Rcpp::wrap (exDate)), Shield<SEXP>(Rcpp::wrap (volatility)), Shield<SEXP>(Rcpp::wrap (dayCounter)));
500521 }
501522 if (rcpp_result_gen.inherits (" interrupted-error" ))
502523 throw Rcpp::internal::InterruptedException ();
0 commit comments