Login  Register

Re: swig some class are not wrapped

Posted by Luigi Ballabio on Mar 03, 2011; 9:41am
URL: http://quantlib.414.s1.nabble.com/swig-some-class-are-not-wrapped-tp6058p6065.html

On Thu, 2011-03-03 at 00:20 -0800, archlight wrote:
> It is the swap.py from examples folder. I am using swig2.0.1 executable.

Does it work if you don't modify volatilities.i and compile the original
files instead?

> by the way, how do I represent std::vector<std::vector<Handle > > in python.
> I am using numpy matrix but it says parameter type not matched
>
> I found something in vector.i but there is no nested vector example.

You must declare to swig that you'll use it--something like

%template() std::vector<std::vector<Handle<Quote> > >;

if I'm not mistaken.  After this, you should be able to pass a list of
lists of handles where std::vector<std::vector<Handle > > is required.

Luigi


--

Glendower: I can call spirits from the vasty deep.
Hotspur: Why, so can I, or so can any man;
But will they come when you do call for them?
-- King Henry the Fourth Part I, Act III, Scene I



------------------------------------------------------------------------------
Free Software Download: Index, Search & Analyze Logs and other IT data in
Real-Time with Splunk. Collect, index and harness all the fast moving IT data
generated by your applications, servers and devices whether physical, virtual
or in the cloud. Deliver compliance at lower cost and gain new business
insights. http://p.sf.net/sfu/splunk-dev2dev 
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users