Java is the popular object oriented programming language. Java was imagined by James Gosling, Patrick Naughton, Chris Warth, Ed Frank, and Mike Sheridan at Sun Microsystems, Inc. in 1991. It took 18 months to develop the first working version. Initially java was known as Oak but later in them named it as java. Java is very similar to C and C++ syntax is similar to C++. Most concepts are similar to C++ like inheritance, overloading, constructor.
FEATURES OF JAVA
- Compiled and Interpreted
Computer languages are either compile or interpreted but java is both it is compile as well as interpreted. First java compiler translates source program into byte code byte code is Bytecode is a highly optimized set of instructions designed to be executed by the Java run-time system. In next stage java interpreter generates machine code that can be directly executed by machine.
- Platform Independent and Portable
Unlike other languages JAVA program can be transported from one platform to other platform very easily without any modification in program; because java is compiled and interpreted language.
- Object Oriented
Java is object oriented programming language everything in java is an object except some primitive data types. Class is template to an object all data and methods are encapsulated inside the class.
- Simple and Familiar
Java is very easy language it provides very simple syntax. Java is familiar to C,C++ so if you have knowledge about C,C++. Then it is very simple to learn java. Java does not use pointer, operator over overloading because it adds ambiguity, java eliminates the concept of multiple inheritance.
Thread is the basic unit of CPU utilization. Thread is also called as light weight process because thread is nothing but a thread is basic unit of CPU utilization because a thread can share resources threads can share code data file stack register etc. All thread run in same address space. A thread is contained inside a process. Java can handle multiple tasks at a time using multiple thread means we need not have to wait for the application to complete one task before beginning another.
Java applets are small java program transported over internet, applet runs inside java compatible browser which support java. Applet can perform different functions like computation, play audio and video file, games etc. applet can be embedded inside webpage using <APPLET> tag. There are two types of applet local applet and remote applet.
Inheritance is the process is process by which objects of one class can acquire the properties of another class for reusability if data inheritance eliminates the redundancy.
Types of Inheritance
1. Single Inheritance:
When one class is derived from another base class or super class then it is called as single inheritance.
2. Multiple Inheritance:
When one class extends more than one super classes then it is called as multiple inheritance. It is not possible in JAVA; functionality can be carried out through interfaces.
3. Hierarchical Inheritance:
When more than one classes extends single base class then it called as hierarchical inheritance.
4. Multi-Level Inheritance:
In this type of inheritance a class is derived from another derived class so this creates multilevel dependency. For more reading about technology news in singapore and seo to online marketing do view more about other pages.