Typemap for char** a

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Typemap for char** a

Andrew-28
I'm trying to create a perl typemap for a function that returns errors
to a char** passed as a parameter. The function looks like this:

void FooInitialize(int nargs, char** arg_list, char** errorsOut);

errorsOut should contain any errors that were encountered within
FooInitialize. I just can't figure out how to get errorsOut to refer to
a PERL array.

I've been reading swig and perl documentation all day today and I can't
find anything. I think I've figured out the char** arg_list because I've
  edited the wrapped code to print out the value of *arg2 and all looks
well.

Also, am I accessing the function the correct way from perl (by passing
the arrays as references)?

@fooargs = ("--port 1234","--config-file foo.xml");
foo::FooInitialize(2,\@fooargs,\@errors);


-------------------------------------------------------
This SF.Net email is sponsored by the JBoss Inc.
Get Certified Today * Register for a JBoss Training Course
Free Certification Exam for All Training Attendees Through End of 2005
Visit http://www.jboss.com/services/certification for more information
_______________________________________________
Swig-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swig-user