What is Java?
Java is a programming language expressly designed for use in the distributed environment of the Internet.It was first released by Sun Micro-systems in 1995.Java was created by a team led by James Gosling for Sun Micro-systems. It was designed to have the “look and feel” of the C++ language, but it is simpler to use than C++ and enforces an object-oriented programming model. Java can be used to create complete applications that may run on a single computer or be distributed among servers and clients in a network. It can also be used to build a small application module or applet for use as part of a Web page. Applets make it possible for a Web page user to interact with the page.
The major characteristics of Java are:
The programs you create are portable in a network. (See portability.) Your source program is compiled into what Java calls byte-code, which can be run anywhere in a network on a server or client that has a Java virtual machine. The Java virtual machine interprets the byte-code into code that will run on the real computer hardware. This means that individual computer platform differences such as instruction lengths can be recognised and accommodated locally just as the program is being executed. Platform-specific versions of your program are no longer needed.
The code is robust, here meaning that, unlike programs written in C++ and perhaps some other languages, the Java objects can contain no references to data external to themselves or other known objects. This ensures that an instruction can not contain the address of data storage in another application or in the operating system itself, either of which would cause the program and perhaps the operating system itself to terminate or “crash.” The Java virtual machine makes a number of checks on each object to ensure integrity.
Java is object-oriented, which means that, among other characteristics, an object can take advantage of being part of a class of objects and inherit code that is common to the class. Objects are thought of as “nouns” that a user might relate to rather than the traditional procedural “verbs.” A method can be thought of as one of the object’s capabilities or behaviours.
In addition to being executed at the client rather than the server, a Java applet has other characteristics designed to make it run fast.
Why you should learn Java Programming Language
Why Java is best Programming language – why learn Java Here is my list of 10 reasons, which I tell anyone who asks my opinion about learning Java, and whether Java is a best programming language in terms of opportunities, development and community support.
1) Java is Easy to learn
Many would be surprised to see this one of the top reason for learning Java, or considering it as best programming language, but it is. If you have a steep learning curve, it would be difficult to get productive in a short span of time, which is the case with most of professional project.
Java has fluent English like syntax with minimum magic characters e.g. Generics angle brackets, which makes it easy to read Java program and learn quickly.
Once a programmer is familiar with initial hurdles with installing JDK and setting up PATH and understand How Classpath works, it’s pretty easy to write program in Java.
2) Java is an Object Oriented Programming Language
Another reason, which made Java popular is that it’s an Object Oriented Programming language. Developing OOPS application is much easier, and it also helps to keep system modular, flexible and extensible.
Once you have knowledge of key OOPS concept like Abstraction, Encapsulation, Polymorphism and Inheritance, you can use all those with Java. Java itself embodies many best practices and design pattern in it’s library.
Java is one of the few close to 100% OOPS programming language. Java also promotes use of SOLID and Object oriented design principles in form of open source projects like Spring, which make sure your object dependency is managed well by using dependency Injection principle.
3) Java has Rich API
One more reason of Java programming language’s huge success is it’s Rich API and most importantly it’s highly visible because come with Java installation. When I first started Java programming, I used to code Applets and those days Applets provides great animation capability, which amazes new programmer like us, who are used to code in Turbo C++ editor. Java provides API for I/O, networking, utilities, XML parsing, database connection, and almost everything. Whatever left is covered by open source libraries like Apache Commons, Google Guava, and others.
4) Powerful development tools e.g. Eclipse , Netbeans
Believe it or not, Eclipse and Netbeans has played a huge role to make Java one of the best programming languages. Coding in IDE is a pleasure, especially if you have coded in DOS Editor or Notepad.
They not only helps in code completion but also provides powerful debugging capability, which is essential for real world development. Integrated Development Environment (IDE) made Java development much easier, faster and fluent. It’s easy to search, refactor and read code using IDEs.
Apart from IDE, Java platform also has several other tools e.g.. Maven and ANT for building Java applications, decompilers, JConsole, Visual VM for monitoring Heap usage etc.
5) Great collection of Open Source libraries
Open source libraries ensures that Java should be used everywhere. Apache, Google, and other organisation has contributed lot of great libraries, which makes Java development easy, faster and cost effective.
There are framework like Spring, Struts, Maven, which ensures that Java development follows best practices of software craftsmanship, promotes use of design patterns and assisted Java developers to get there job done.
I always recommend to search for a functionality in Google, before writing your own code. There is good chance that, it’s already coded, tested and available for ready to use.
6) Wonderful community support
Community is the biggest strength of Java programming language and platform. No matter, How good a language is, it wouldn’t survive, if there is no community to support, help and share there knowledge. Java has been very lucky, it has lots of active forums, Stackoverflow, open source organisations and several Java user group to help everything.
There is community to help beginners, advanced and even expert Java programmers. Java actually promotes taking and giving back to community habit. Lots of programmers, who use open source, contribute as committer, tester etc. Expert programmer provides advice FREE at various Java forums and stackoverflow. This is simply amazing and gives lot of confidence to a newbie in Java.