10. What is Just in Time Compiler ?
Java Development Kit (JDK) is a superset of the JRE, which contains Java Run-time Environment (JRE) , Compilers and debuggers required to develop applets and applications.
Class loader is used to load all the classes required to execute the application into the Java Virtual Machine (JVM). Once the classes are loaded, the memory required for the application is determined.
14. What is byte code verifier ?
Byte code verifier checks for illegal code like forged pointers, violated access rights on objects etc. in complied byte code.
15. What are the java verifications done by byte code verifier ?
1. Check whether classes follow JVM specification for classes 2. Check for stack overflows 3. Check for access restriction violations 4. Illegal data conversions
16. What is Java API?
An application programming interface (API) is a library of functions that Java provides for programmers, for common tasks like file transfer, networking, and data structures.
17. Give Some examples of Java API.
- Java.applet - Applet class
- Java.awt - Windows, buttons, mouse, etc.
- Java.awt.image - image processing
- Java.awt.peer - GUI toolkit
- Java.io - System.out.print
- Java.lang - length method for arrays; exceptions
- Java.net - sockets
- Java.util - System.getProperty
18. What is an applet?
An applet is a small Java program that runs within a web page on your browser. Unlike a traditional desktop application, an applet is severely limited as to what it can perform on your desktop.
- Applet read and write files.
- Applet integrates with desktop services (e.g., e-mail).
- It is connected to other servers.
- It is also built with security in mind.
- If the user allows, an applet can be given more authority.
Java OOPS Interview Questions and Answers
19. What is a class?
Classes are used to define objects of a certain type. For example - Car, Person etc. To define the characteristics of a class, variables and the methods are used.
20. What is an object?
An object is an instance of a classes, which has it's own private collection of properties (i.e. data) and methods (i.e. operations).
21. What an object contains?
An object has - State and Behavior
22. What is object oriented program?
An Object-Oriented Program consists of a group of cooperating objects, exchanging messages, in-order to achieve a common objective.
23. What are the benefit's of OOPS?
- Real-world programming
- Reusability of code
- Modularity of code
- Resilience to change
- Information hiding
24. What are the features of OOPS?