Java Questions Flashcards
What is meant by the statement Java is platform independent?
Java is compiled into byte code, and can by run on any JVM, making it interoperable on any underlying hardware and OS.
What is meant by the Java platform?
The platform includes the Java Language Specification and the Java Virtual Machines Specification
What is the Java API?
Collection of software components that provide many useful capabilities the come prepackaged with JDk. Grouped into libraries of related classes.
What is the JRE?
Includes JVM and APIs. JRE contains enough to execute a Java app but not to compile it
What is the JDK?
JRE plus Javac. Only full Java SDK contains the javac which turns .java source files into byte code .class files.
What is the JVM?
Implementation of specification that details the behavior of a JVM.
Runs code compiled into bytecode, irrespective of language.
Java launcher tool runs application inside of JVM. JRE is the implementation of the JVM
What is the Class loader subsystem in the JVM
Takes care of finding and loading types
Also locate binary data for classes. Allocates and initializes memory for class variables
Runtime data area in JVM
Consists of method area, heap area, stack, pc registers, native stack
Execution engine JVM
Execution of the actual bytecode
Interpreter, just-in-time compiler, and garbage collector
If you launch three programs on the same machine, how many JVMs are created
- Only one app can run within JVM.
What is fat jar
Contains all project class files and classes from all the libraries on which the project depends.