Login  Register

Getting the latestDate() from a SwapRateHelper object (using C# SWIG Bindings)

Posted by Ahmad Mahomed on Oct 29, 2010; 5:51am
URL: http://quantlib.414.s1.nabble.com/Getting-the-latestDate-from-a-SwapRateHelper-object-using-C-SWIG-Bindings-tp8721.html

Using the C# SWIG bindings, how does one get the value of the  `latestDate()` from a SwapRateHelper defined as 

             var daysTillLast = curveEndDate.serialNumber() - TodaysDate.serialNumber();
             var newFwdSwap = 
                    new SwapRateHelper(
                        swapRate,
                        new Period(10,TimeUnit.Years),
                        SouthAfricanCalender,
                        Frequency.Quarterly,
                        DayConvention,
                        Actual365FixedDayCounter,
                        new Jibar(new Period(Frequency.Quarterly),DiscountingTermStructure),
                        0 /*zero spread */, 
                        new Period(daysTillLast,TimeUnit.Days) /* fwdStart */
                    );

The latestDate() is part of the the functionality of the  'RelativeDateBootstrapHelper<YieldTermStructure>' object.

Note: I created the the above ctor since it was not defined in the SWIG files. I need to test this and if it works I will submit a patch for the files if its valid.


--
Ahmad Mahomed

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users