Alternative technologies to replace applet?

后端 未结 3 1674
被撕碎了的回忆
被撕碎了的回忆 2021-01-03 01:47

I have an (unsigned) applet that let you draw a logic circuit and test it on-screen (a bit like Electronics Workbench), and it then serializes the circuit (the internal form

相关标签:
3条回答
  • 2021-01-03 01:59

    You can still run unsigned java applets in your web pages if you block your Java plugin in the browser to the version SE 7 U11 (jre-7u11-windows-i586.exe) Of course you will have to block automatic Java update with "C:\Program Files (x86)\Java\jre7\bin\javacpl.exe" I hop you can survive for a while this way, before you find an alternative to JAva applet. In HTML5 the tag to call an apllet is now object and the syntax is a bit different:

    <object codetype="application/java" 
            classid="yourApplet.class"
            codebase="http://www.yourserver ..."
            archive="YourJarFile.jar"
            width="x" height="y">
            <param name="paramName1" value="paramValue1"/>
            <param name="paramNamei" value="paramValuei"/>
    </object>
    
    0 讨论(0)
  • 2021-01-03 02:07

    I can't comment on what you found about applets, since I never wrote one.

    If you want to move away from them, maybe your only option (while staying with Java) is go for web applcations, where the code is most on server-side and you interact with your software directly in your browser. On the client-side javascript (and js-related libraries like JQuery) is used, though I can't elaborate about it more since I'm don't know the Java EE stack very well yet.
    I'm not sure if you can get 100% the same user experience as you currently have in your applet, above all for an electronics application. But it may offer the highest code-reuse of most of your Java classes.

    I've used Vaadin, it's a framework that moves almost all your coding to the server-side (you only need to code the client side if you want to create addons). I've heard about Zk too, but I've never used it, so I can't say anything about it.

    0 讨论(0)
  • 2021-01-03 02:13

    (Which sounds like it means "Future updates will deny the execution of Java applications" -- unless you pay money to Thwaite or Verisign on a regular basis AND expose users to code running outside a sandbox.)

    A signed applet launched using JNLP can still be sand-boxed.


    But if you really wish to avoid it..

    I think what you described can be provided using JavaScript for the logic and and an HTML 5 canvas for the rendering.

    I would avoid Flash, since it is also susceptible to security bugs. It would be like digging yourself a brand new hole to get trapped in.

    0 讨论(0)
提交回复
热议问题