help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Swig works (Re: Octave and databases)


From: John W. Eaton
Subject: Re: Swig works (Re: Octave and databases)
Date: Thu, 9 Sep 2010 12:43:48 -0400

On  8-Sep-2010, Xavier Delacour wrote:

| Yes, the question was about putting multiple functions into a single
| m-file.

Octave supports subfunctions, same as Matlab, but only the first
function in the .m file is directly callable by the user.

| More important is the support for handle classes (destructors +
| copy-by-ref). That is required to use octave classes to wrap C
| classes.

Exactly what do you mean by copy-by-ref?  I've written a lot of
wrappers for C and Fortran code and have not needed to pass variables
by reference or to have destructors.  Can you give an example of why
these things are needed?

| Hacks like making static methods and variables appear as global
| methods and variables are okay. Eg, static methods could be made to
| appear as class_name_static_method_name() from octave. Static
| variables are a bit trickier since the wrapper needs to told when
| assignment happens (so it can assign the C-side variable). xyz_set()
| and xyz_get() functions can also be generated for static variable
| access.

Exactly what do you mean by "static methods and variables"?  In what
language?  Can you give an example of what you are describing above?
That might help me to better understand the issues you are facing and
perhaps offer some suggestions.

jwe


reply via email to

[Prev in Thread] Current Thread [Next in Thread]