Thursday Mar 12, 2009

JavaFX and Ajax

Ken Russell, the architect and author of the new Java Browser plugin has recently completed the work on the JavaFX to JavaScript bridge. In a nusshell, JavaFX web applications could call JavaScript functions & objects in the webpage that embeds the JavaFX app and vice versa. Nota bene: this bridge calls for the plugin to use Java SE 6 update 10 or later.

JavaScript to JavaFX Script

JavaFX Script can be accessed using the synthetic script field which is exposed from JavaFX Script applets to the JavaScript engine.

function someJavaScriptCall() {

var myApp = document.getElementById("myApplet";);

myApp.script.someJavaFXScriptCall();

}

The snippet above, assumes that the Java web application (Applet) embedded in the web page is instantiated with myApplet as id.

JavaScript to JavaFX Script

JavaFX Script can interact with JavaScript on the web page, in a similar way to how Java code can interact with JavaScript. This lets you call JavaScript functions defined on the web page, modify the Document Object Model (DOM) of the web page on the fly, and generally write JavaFX Script apps that integrate well within the web page.

AppletStageExtension.eval("yourJavaScriptCall()";);

Wednesday Mar 05, 2008

Ajax support in NetBeans

If you've read my previous post on charting for web applications using jMaki, here is another installment on the Ajax capabilities of NetBeans. The 6.1 beta release (due to be released tomorrow 3/6/08) improves on the previous feature set and as far as JavaScript support is concerned, it kicks butt!

So what's on tap?

 

  • JavaScript support in the editor - if you make heavy use of JavaScript in your web apps, NetBeans 6.1 brings the language to life
  • Better support for MySQL - ability to register MySQL servers
  • Performance improvements - especially in startup and project open visual JavaServer Facess application development
  • Support for PHP is still experimental (available on the update center), so I suggest for folks to wait until early April to kick the tires of the PHP support
Check out this wiki page for some more details on the Ajax related functionality as well the new & noteworthy wiki on NetBeans 6.1 beta.

 

About

octav

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today