• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 23. Using JavaScript to Control ... > JavaScript to Java Communication

JavaScript to Java Communication

With LiveConnect, JavaScript can make calls directly to Java methods. As already shown in the "The Java Console" section, this is how JavaScript can output messages to the Java Console. To JavaScript, all Java packages and classes are properties of the packages object. Therefore, the full name of a Java object in JavaScript would be something like packages.packageName.className.methodName.

Tip

The packages name is optional for the java, sun, and netscape packages.



PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint