Re: extracting "Arguments" from "Instrument"

Posted by Luigi Ballabio-2 on
URL: http://quantlib.414.s1.nabble.com/extracting-Arguments-from-Instrument-tp3059p3060.html

On 2004.07.12 20:28, Michael Dirkmann wrote:
> is there a way to extract the 'Argument*' from an 'Instrument'?
> In my special case I would like to extract the Swaption::arguments*
> from a Swaption to provide it to the swaption-function of the G2-
> model.

Michael,
        the following should work:

Swaption swaption(...);
Swaption::arguments args;
swaption.setupArguments(&args);

The same applies to all instruments providing arguments.

Later,
        Luigi