/trunk/Examples/test-suite/rename_simple.i
Swig | 24 lines | 21 code | 3 blank | 0 comment | 0 complexity | 4ec0ca2d10d5590a596a1d94569087f7 MD5 | raw file
Possible License(s): LGPL-2.1, Cube, GPL-3.0, 0BSD, GPL-2.0
- %module rename_simple
- %rename(NewStruct) OldStruct;
- %rename(NewVariable) OldVariable;
- %rename(NewInstanceMethod) OldInstanceMethod;
- %rename(NewInstanceVariable) OldInstanceVariable;
- %rename(NewStaticMethod) OldStaticMethod;
- %rename(NewStaticVariable) OldStaticVariable;
- %rename(NewFunction) OldFunction;
- %rename(NewGlobalVariable) OldGlobalVariable;
- %inline %{
- struct OldStruct {
- OldStruct() : OldInstanceVariable(111) {}
- int OldInstanceVariable;
- int OldInstanceMethod() { return 222; }
- static int OldStaticVariable;
- static int OldStaticMethod() { return 333; }
- };
- int OldStruct::OldStaticVariable = 444;
- int OldFunction() { return 555; }
- int OldGlobalVariable = 666;
- %}