Posted by
Luigi Ballabio on
Mar 01, 2012; 1:01pm
URL: http://quantlib.414.s1.nabble.com/extending-instrument-question-tp204p205.html
Hi Pepe,
in the short term I'd abuse the pricing engine. Not that it's
much of an abuse.
For the long term, I'm not sure, but then again I think I haven't
grasped the problem yet. Do you have a use case you can share?
Luigi
P.S. Not sure about the visitor pattern. It would require your
visitor to specialize for all instruments, giving lots of coupling in
a single class.
On Wed, Feb 22, 2012 at 9:51 AM, <
[hidden email]> wrote:
> The library is pricing oriented, ok; but say I want to use Instruments for other things like mitigation, c.v.a, etc... So I need to ask an instrument for something else. I have tried some solutions which are not very neat, decorating them, abusing the PricingEngine concepts for other things than pricing, etc... Also wondered if all instruments were visitable would it allow one to do this?
> Is anyone else in this situation? and whats the correct way to do it?
> Thanks
> Pepe
>
> ------------------------------------------------------------------------------
> Virtualization & Cloud Management Using Capacity Planning
> Cloud computing makes use of virtualization - but cloud computing
> also focuses on allowing computing to be delivered as a service.
>
http://www.accelacomm.com/jaw/sfnl/114/51521223/> _______________________________________________
> QuantLib-users mailing list
>
[hidden email]
>
https://lists.sourceforge.net/lists/listinfo/quantlib-users------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users