RE: java interface
Posted by Luigi Ballabio-3 on Jul 10, 2001; 4:07pm
URL: http://quantlib.414.s1.nabble.com/java-interface-tp1736p1739.html
Hi all,
news from the SWIG side: release 1.3.6 is sound and can be used to
create useable Java interfaces. As soon as it is actually released, and if
there is any interest from anyone, we could spin off a QuantLib-Java module
parallel to QuantLib-Python and QuantLib-Ruby.
On to Gilbert's question (by the way, how do you pronounce your name? The
english way? The french way? Some other way?):
At 11:59 AM 7/10/01 +0200, Gilbert Peffer wrote:
>I was told that if you can't interface C++ from within a Java applet, or at
>least that the applet won't work. Does anybody know anything about this?
Well, an applet is downloaded and executed client-side in the browser
virtual machine. The browser will not download and load a C++ shared
library to go with the applet - besides mere reasons of portability of the
compiled code, an applet has strong security restrictions which make it
impossible to execute non-Java code. The VM has no means to know what the
C++ code does (it could format your disk and such), so it does the safe
thing and stays away from it.
What you can do is to use a servlet instead, which is executed server-side
and dynamically generates HTML to be sent to the browser. You can compile
and install the C++ extension on the web server where the servlet runs, and
it will be loaded and work its magic.
Bye,
Luigi
-----------------------------------------------------
In case you found the label [Mail virus free] in the subject of this mail,
that is only because I forgot to remove it before replying.
The label was added by our new internet provider - they want to make the
point that they practice safe mailing. Of course we all know that there is
no such thing, therefore you can happily disregard it.