I have the next definition in a file:
File: one.h
typedef struct example example;
And in other file I have the implementation of the struct:
File: two.h
typedef struct example1{
int four;
} example1;
struct example {
int one;
example1 four;
};
File: swig.i
¿?
File wrapper.java
class SWIGTYPE_P_example;
// I want to have: class example;
When I compile, swig generate the class SWIGTYPE_p_example, instead of the object
example.
I understand that the declaration of my struct is unknow and this is the reason because I have the SWIGTYPE, but, are there any way to have into the wrapper the correct class?
The solution was to redefine my typedef in the my swig.i file
File: swig.i
typedef struct example1{
int four;
}