PageRenderTime 17ms CodeModel.GetById 15ms app.highlight 0ms RepoModel.GetById 1ms app.codeStats 0ms

/trunk/Examples/test-suite/director_constructor.i

#
Swig | 37 lines | 26 code | 11 blank | 0 comment | 0 complexity | 5ce620c7a135057901e49f791a373327 MD5 | raw file
 1%module(directors="1") director_constructor
 2
 3%feature("director") Foo;
 4
 5%inline %{
 6class Foo
 7{
 8public:
 9  int a;
10  
11  Foo(int i)
12  {
13    a=i;
14  }
15  
16  virtual ~Foo() { }
17  
18  int do_test() {
19    return test();
20  }
21  
22  virtual int getit()
23  {
24    return a;
25  }
26  
27  virtual void doubleit()
28  {
29    a = a * 2;
30  }
31  
32  virtual int test() = 0; 
33};
34%}  
35  
36
37