Introduction to Java Programming Language |
Java is a very famous high
level programming language. Java was developed at Sun Microsystems in the early 1990s and
is based on C++. It looks very similar to C++ but it is significantly
simplified as compared to C++. This is the reason why Java is sometimes referred to as C++--. Java is a
pure Object Oriented Programming Language. Everything in Java is an object. Java has eliminated many C++ concepts, like
multiple inheritance, pointers, structs, enum types, operator overloading, goto statement, etc. Java is a platform independent programming language. Without
even a recompile, a Java executable can run on any JVM enabled platform. Java is also
network friendly for its portable and threaded nature and because of its rich
network libraries. Java provides an extensive support for the development
of web and enterprise
applications. Servlets, JSP,
Applets, JDBC, RMI, EJBs and JSF etc. are some of the Java technologies that
are used to build the web and enterprise applications.
Java versus C++:
Generally, Java is more robust than C++. Some of
the reasons are:
·
Object handles are
initialized to null (a keyword)
·
Handles are always
checked and exceptions are thrown for failures
·
All array accesses
are checked for bounds violations
·
Automatic garbage
collection prevents memory leaks and dangling pointers
·
Type conversion is
safer
·
Clean, relatively
fool-proof exception handling
·
Simple language
support for multithreading
·
Bytecode verification
of network applets