Would it be appropriate to use j2s to convert applets to web applications

73 views
Skip to first unread message

ryosua

unread,
May 13, 2013, 2:10:25 PM5/13/13
to java2...@googlegroups.com
I've been looking into the viability of using java2script to convert a few applets to web applications(HTML, javascript, CSS). From what I have seen so far, it seems like this would not be the best tool for that purpose. The applet that I would be converting first is built around the swing library. Does java2script support swing? The goal would be to create a standalone web application that does not rely on java2script, or Java. Thanks. 

Zhou Renjian

unread,
May 13, 2013, 11:26:51 PM5/13/13
to Java2Script
Java2Script does not provide JavaScript Swing library. It currently provide Java2Script SWT library.

Some years ago, I tried to use swingwt ( http://swingwt.sourceforge.net/ ) to build Java2Script Swing library. It seemed the job is feasible but need a lot of time. As I did not have enough time to do so, I stopped.

Not sure about your goal. If you want to support converting Applet to web, you may rely on tools. Maybe you means that once you have the Applet library in JavaScript, you can write your web app in JavaScript instead Java. In such cases, I suggest you using existed JavaScript library instead of creating another one from existed Java sources. JavaScript language model is different from Java language model. You may come up with many difficulties and may waste your time. Existing YUI, may be your choice.


Regards,
Zhou Renjian


On Tue, May 14, 2013 at 2:10 AM, ryosua <ryo...@gmail.com> wrote:
I've been looking into the viability of using java2script to convert a few applets to web applications(HTML, javascript, CSS). From what I have seen so far, it seems like this would not be the best tool for that purpose. The applet that I would be converting first is built around the swing library. Does java2script support swing? The goal would be to create a standalone web application that does not rely on java2script, or Java. Thanks. 

--
You received this message because you are subscribed to the Google Groups "Java2Script" group.
To unsubscribe from this group and stop receiving emails from it, send an email to java2script...@googlegroups.com.
To post to this group, send email to java2...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/java2script/cde92505-6c0b-4abe-97cf-ef49aed58608%40googlegroups.com?hl=en-US.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

robert....@twc.com

unread,
Oct 8, 2013, 12:09:51 PM10/8/13
to java2...@googlegroups.com
If I can contribute here, I would very much like to see Java2Script convert Swing applets.  With all of the security and performance problems of Java recently, I am trying to replace all Java applets in my Web application with JavaScript applications that have the same functionality.  (The model I am using is the chemistry applet Jmol, which now has a JavaScript version called JSmol.)  Unfortunately, the one applet that we wrote ourselves uses Swing and AWT packages, and I'm gathering from this conversation that Java2Script won't convert it.  So I would encourage you to extend Java2Script to handle Swing applets.
Reply all
Reply to author
Forward
0 new messages