Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I had this conversation yesterday with a friend of mine and I was trying to explain to him that applets are precompiled code that is loaded by the JVM through the Java browser plugin. I am trying to find some documentation or a detailed description of what is going on in the browser when a site with an applet is visited and eventually how it gets loaded, but couldn't.

Could anyone please provide some insight?

share|improve this question
add comment

1 Answer 1

Quick answer: Java source code in .java files is compiled to .class files that contain Java byte code. These are packaged into a single .jar file. The web page HTML includes a reference to this jar file. The browser fetches the jar, fires up the locally installed Java Virtual Machine (JVM) and hands it the jar file data. The JVM then does Just-In-Time (JIT) compilation of byte-code to native code as necessary.

Oracle have provided some information on Applet launching

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.