Introduction to Java

Java is a high-level, object-oriented, robust and secure programming language used for application development.

History of Java

Founder of Java

Patrick Naughton, an engineer at Sun Microsystems, was frustrated at Sun’s APIs and tools that were using C and C++. He along with James Gosling and Mike Sheridan created The Green Project and were given the opportunity to develop a language which had to be:

  1. “simple, object-oriented and familiar”
  2. “robust and secure”
  3. “architecture-neutral and portable”
  4. able to execute with “high performance”
  5. “interpreted, threaded and dynamic”

James attempted to modify and extend C++, which he referred to as C++ ++ --, but abandoned it due to its complexity in handling system memory. It was then decided to create a completely new language named Oak, after a tree that grew outside Gosling’s office.

Work on the language had begun in 1991, and before long the team’s focus changed to a new niche, the World Wide Web. About the completion of the project, Naughton said,

"In 18 months, we did the equivalent of what 75-people organizations at Sun took three years to do. An operating system, a language, a toolkit, an interface, a new hardware platform, three custom chips ... using new risky technology at every turn. We pulled out all our teeth and put them in each others' mouths."

In 1994, the language was renamed Java, as Oak was already trademarked for another language. Java was released on 23 May 1995 and its ability to provide interactivity and multimedia showed that it was particularly well suited for the Web.

By the late 1990s, Java had brought multimedia to the Internet and started to grow beyond the Web, powering consumer devices such as cellular telephones, retail and financial computers, and even the onboard computer of NASA’s Mars exploration rovers.

In 2010 the Oracle Corporation took over the management of Java when it acquired Sun Microsystems.

Features of Java

Simplicity

Java is simpler than most other languages that are used to create server applications, because of its consistent enforcement of the object model. The large, standard set of class libraries brings powerful tools to Java developers on all platforms.

Object-Oriented

OOP Java is truly an object-oriented language. All parts of an application are managed with classes and objects.

Robust

Java programs are robust because Java performs automatic garbage collection i.e. JVM automatically performs all memory allocation and deallocation while the program is running and provides exception handling mechanisms to prevent the system from crashing.

Secure

security in java The design of Java bytecodes and JVM specification allow for built-in mechanisms to verify the security of Java code.

Platform-Independent and Portable

Platform independence of Java Java programs can be described as WORA (Write Once Run Anywhere). Java is portable across platforms i.e. it can be easily moved from one computer system to another. This architecture neutrality is possible because the Java compiler creates an intermediate code called bytecode which is platform-independent. This code is converted to platform-specific machine code by the JIT compiler.

Multithreaded

multithreaded Java

Java allows us to write programs that can perform many tasks simultaneously. We can increase the efficiency of our output using this.

No pointers

no poiners in Java

Although Java is quite similar to C in its syntax, it does not support direct pointers or pointer manipulation. You pass all parameters, except primitive types, by reference and not by value. As a result, the object's identity is preserved. Java does not provide low level, direct access to pointers, thereby eliminating any possibility of memory corruption and leaks.

Standards for connectivity to relational databases

jdbc in Java

Java Database Connectivity (JDBC) and SQLJ enable Java code to access and manipulate data in relational databases. Oracle provides drivers that allow vendor-independent, portable Java code to access the relational database.

10
Subscribe to my newsletter

Read articles from V Krishnasubramaniam directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

V Krishnasubramaniam
V Krishnasubramaniam