|
From: | Michael Goffioul |
Subject: | Re: loadlibrary... again |
Date: | Thu, 21 Nov 2013 10:44:44 -0500 |
Hello,
I hope this is the right place to ask this. This is my first post and I am
very new to Octave.
I have a shared library that has several bindings (c/c++, Matlab, Java,
Python, Urbi). I want to make that library available in Octave.
So I understand there is no equivalent of loadLibrary in Octave. But how can
I handle following scenario in Octave (imagine the xxx-functions are
functions in my shared library, called via Octave):
clientId=xxxStartCommunicationWithServer(Ip,port)
xxxSendMessage(clientId,"Hello")
...
xxxStopCommunicationWithServer(clientId)
in above code, xxxStartCommunicationWithServer will start a communication
thread, connect to the server and stay connected until
xxxStopCommunicationWithServer is called.
If I use the Oct-file approach, each call to a xxx function will:
- load the library
- call the function
- unload the library
The unload of the library will automatically kill the communication thread
and release all memory/variables that were allocated during the call to
xxxStartCommunicationWithServer.
[Prev in Thread] | Current Thread | [Next in Thread] |