On Wed, Oct 10, 2012 at 11:32 PM, Craig Wright <firstname.lastname@example.org>
The SWIG documentation on the SWIG website and the examples shipped
with the source code are really quite good. It's all I needed to get
up to speed with the basics. For what it's worth, I use it with
On Tue, Oct 9, 2012 at 10:25 PM, Hank Finley <email@example.com> wrote:
> Hi, as the title suggests I am looking to learn SWIG, I am especially
> interested in wrapping a c api to java. Over the last two weeks I have been
> sending out posts to this list plus stack exchange with little luck.
> Is there some place online or books I can buy to speed things up?
> I guess I am looking for more examples and tutorials online than what is
> supplied in the SWIG and Java, typemaps especially.
> Definitely not knocking whats out there.
> Any suggestions are appreciated!
> Regards Hank
I have been trying to do something similar to the examples, just a little different, it is the
Using typemaps to return arguments except I would like the status, one int and one string to be returned.
my function is:
reader and field_num are input, status, type and value needs are output, so I figure "Using typemaps to return arguments" is the way to go, however, as in the example I would need to create structs (classes) for type and value and populate them with the int and char ** respectively.
int gaiaTextReaderFetchField (gaiaTextReaderPtr reader, int field_num, int *type, const char **value);
The populating of these two structs which would be done within a typemap(out), I guessing, is where I am lost.
Not sure if much Java is done here, seems to be a lot of Python and Tcl, very frustrated, not with anyone, just with my own lack of progress. So I am searching for other learning sources.